Results 1 to 2 of 2
  1. #1
    3 Star Lounger
    Join Date
    Jan 2001
    Location
    Serbia and Montenegro (Yugoslavia)
    Posts
    342
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Changes to data using cn.execute (VB6 & Access 2K)

    I am updating an Access 2K database using the connection.execute method and running an update query. When I re-populate a ListView control, the changes are not displayed right away. When I use a recordset object it displays the changes fine. The changes do occur using the connection object, but you have to close and reopen the entire record.

    I am about to change the methodology I'm using to incorporate a recordset object to make the update, but is there a practical way to make the cn.execute method work?

  2. #2
    3 Star Lounger
    Join Date
    Jan 2001
    Location
    Serbia and Montenegro (Yugoslavia)
    Posts
    342
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Changes to data using cn.execute (VB6 & Access 2K)

    Okay, I'm replying to my own post here. Since I figured it out I thought I would officially answer my own question (well, and also in case anyone else had the same problem).

    I wrapped a cn.BeginTrans and cn.CommitTrans around the execute statement. It works great, and it may be my imagination, but it seems like it executes faster than a recordset object would.

Posting Permissions

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