M
M Skabialka
In Access 2003 I borrowed this code from an earlier datase, but I get a
run-time error.
Dim db As Database
Dim rs As DAO.Recordset
Set db = CurrentDb
Set rs = db.OpenRecordset("tblDocument") ' Run-time error
'13': Type Mismatch
'Do stuff....
rs.Close
End If
I checked my references. They are:
Visual Basic for Applications
Microsoft Access 11.0 Oblect Library
Microsoft DAO 3.6 Object Library
OLE Automation
Microsoft ActiveX Data Objects 2.1 Library
The recordset ends up set to nothing, not to the table "tblDocument".
What am I doing wrong here (my first Access 2003 database from scratch)?
Thanks,
Mich
run-time error.
Dim db As Database
Dim rs As DAO.Recordset
Set db = CurrentDb
Set rs = db.OpenRecordset("tblDocument") ' Run-time error
'13': Type Mismatch
'Do stuff....
rs.Close
End If
I checked my references. They are:
Visual Basic for Applications
Microsoft Access 11.0 Oblect Library
Microsoft DAO 3.6 Object Library
OLE Automation
Microsoft ActiveX Data Objects 2.1 Library
The recordset ends up set to nothing, not to the table "tblDocument".
What am I doing wrong here (my first Access 2003 database from scratch)?
Thanks,
Mich