Type Mismatch

K

Kevin

I try to run some codes from an example in the Access help
but I have problem.

The example is

DIM dbs AS Database, rst As Recordset
DIM strSQL As string

SET dbs = CurrentDb
strSQL = "SELECT * FROM TABLE1"
SET rst = dbs.OpenRecordSet(strSQL)
....

First of all, I had an user undefined error on the
Database object and I was told that I need to select the
DAO 3.6 under the Reference, Tool menu. So I did and it
solved the problem. Then I have another error "Type
Mismatch" on SET rst = dbs.OpenRecordSet(strSQL) line.

Does anyone know why?

Many thanks


Kevin
 

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