Results 1 to 2 of 2

Thread: VBA Access: Deleting entries in a recordset

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2005
    Posts
    6

    VBA Access: Deleting entries in a recordset

    I am trying to iterate through a recordset and delete records as I go, but first I do some things with the data.

    VB Code:
    1. Do Until source.EOF
    2.             ....
    3.             source.Delete
    4.             source.MoveFirst
    5. Loop

    It appears that every time, the 2nd record get's skipped. And I have to run the code a second time to make sure it gets the 2nd record. I swear this wasn't happening before, bt I don't know. Do you know what would cause something like this with ONLY the second record?

  2. #2
    PowerPoster Static's Avatar
    Join Date
    Oct 2000
    Location
    Rochester, NY
    Posts
    9,390

    Re: VBA Access: Deleting entries in a recordset

    did u try requery/refresh after each delete?
    JPnyc rocks!! (Just ask him!)
    If u have your answer please go to the thread tools and click "Mark Thread Resolved"

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