Re: Clearing a recordset
From: Val Mazur (group51a_at_hotmail.com)
Date: 06/24/04
- Next message: Val Mazur: "Re: Problem: Insert one single record in a access DB using DB"
- Previous message: ckone: "Access Switchboard"
- In reply to: Alan Hood: "Clearing a recordset"
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 23 Jun 2004 22:01:07 -0400
Hi Alan,
There is no direct way to do this, since Delete method deletes only current
record or group of the records, which belong to the specific group, like
Appended, Conflict records. You have several choices
- To loop and delete all the records one-by-one.
- Initialize recordset variable again ant it will delete all the records.
- Filter recordset using condition, when you will not have any matching
record. In this case you will get empty filtered recordset. Then save this
filtered recordset into ADO Stream. In this case stream will contain empty
recordset. Now load recordset back from the stream and you will get empty
recordset.
-- Val Mazur Microsoft MVP "Alan Hood" <hood@dial.pipex.com> wrote in message news:OVSLHbTWEHA.2176@TK2MSFTNGP11.phx.gbl... > Can anybody tell me a simple way to clear a recordset of all its records. > > I'm sure I could do it with .delete but have been unable to do so > > Many Thanks > > Alan Hood > > -- > >
- Next message: Val Mazur: "Re: Problem: Insert one single record in a access DB using DB"
- Previous message: ckone: "Access Switchboard"
- In reply to: Alan Hood: "Clearing a recordset"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|