Results 1 to 2 of 2

Thread: Data control in VB

  1. #1

    Thread Starter
    Hyperactive Member Radames's Avatar
    Join Date
    Feb 2001
    Location
    Tech Tropics
    Posts
    360

    Data control in VB

    Hello people. I am trying to use a button to move on to the next record in the database but I get an "action was cancelled by associated object" error. The code it points to is:

    Data1.Recordset.MoveNext

    And in the problem definition it says "identifier under cursor in undefined"

    If I use the arrows in the Data control it works fine. Can somebody tell me what Im doing wrong?
    Top Tip: You can make friends and impress the opposite sex at geeky cocktail parties by saying "DB" instead of database. - Karl Moore

  2. #2
    PowerPoster Beacon's Avatar
    Join Date
    Jan 2001
    Location
    Pub Floor
    Posts
    3,188
    Hmm could be a range of things!

    Try testing for EOF(end of file)

    On your button:
    VB Code:
    1. Data1.Recordset.MoveNext
    2. If Data1.Recordset.EOF = True Then
    3. MsgBox ("Already At last record")
    4. End If

    Else whats your property for Default cursor type?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width