Conversion from 97 to 2002

  • Thread starter Thread starter Z. Obert
  • Start date Start date
Z

Z. Obert

I have a non-updatable query that I open from code like
the following:

Set Qdf = currentdb.QueryDefs("Query1")
Qdf ("[Enter Number1]") = Num1
Qdf ("[Enter Number2]") = Num2
Set Rst=qdf.openrecordset(dbopensnapshot)

This works fine in Access 97, but when I convert it to
Access 2002, I get an error message on the last line
stating "Runtime Error 3001: Invalid Arguement". I think
it may have to do with the query not being updatable, but
I can't change my table structure around to make the query
updatable.

Any Ideas?
 
ACCESS 97 uses the DAO object library by default. ACCESS 2002 and 2002 use
ADO library by default. Open the Visual Basic Editor and set a reference to
the DAO library (DAO 3.6). Then disambiguate your dimensions by prefixing
them with DAO.

Dim Qdf As DAO.QueryDef


If you know that you won't use ADO, then deselect it from the list of
references.
 
Back
Top