You receive a "Type mismatch" error when you run the OpenRecordset method
 Email
 Print
Symptoms
If you dimension an object as a Recordset and then set that object to databaseobject.OpenRecordset(source), you may receive the following error message:
Run time error '13': Type mismatch
Cause
If your project contains references to both the Data Access Objects (DAO) library and the ActiveX Data Objects (ADO) library, you may see multiple Recordset entries in the list when you dimension the Recordset object. This error occurs when you list the ADO library with a higher priority than the DAO library in the References dialog box, regardless of which Recordset entry you select from the list.
ResolutionANADMANNI

Be a part of the DaniWeb community

We're a friendly, industry-focused community of
1.18 million developers, IT pros, digital marketers,
and technology enthusiasts learning and sharing knowledge.