Can you query a record set?

pdbowling

Registered User.
Local time
Today, 23:13
Joined
Feb 14, 2003
Messages
179
I have a recordSet from a form.

Dim rst As DAO.recordSet
Set rst = Me.recordSet

When I type rst dot and look at the pop up list of methods, I don't see any indication of the ability to query this recordset.

Am I just missing it?

If there's no way to query a recordSet, are there any suggestions for using alternate procedures?

Thanks everyone.
PB
 
In Access 97, you can do something like this:

'sequentially process all records in a table, displaying
'the value of the field MyField for each record.
Dim db as Database, rs as Recordset
Set db = CurrentDb
Set rs = db.OpenRecordset("MyTable")
With rs
Do While Not .EOF
MsgBox !MyField
.MoveNext
Loop
End With
'clear object references
Set rs = Nothing
Set db = Nothing

In later versions of Access you can do the same thing but the syntax is a bit different, or you can use one of the newer data access technologies those versions provide (ADO, RDO, etc.).
 
What do you want to query for?
 

Users who are viewing this thread

Back
Top Bottom