recordset problem object required

S

Steven Scaife

ok i have the following code

Dim db As Database
Dim rst As Recordset


Set db = CurrentDb()
Dim vLocation As String
Dim vManual As String
Set rst = CurrentDb.OpenRecordset("SELECT Location, Manual_Name FROM
OutGoing WHERE Booked_Out_To = '" & Combo7.Value & "'", dbOpenDynaset)
vLocation = rst!Location
vManual = rst!Manual_Name
Combo10.Value = vLocation
Combo12.Value = vManual
Set db = Nothing

when i run the code i get an error on the set rst line. Object required. I
cant understand whats missing. In ASP its basically the same piece of code.
am i missing a reference or something. I have also tried rst as
dao.recordset. but i still get the same error.

thanks in advance for any help
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top