Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VB Uses Access 97 Driver Instead Of Access 2000

Status
Not open for further replies.

Ramjet

Programmer
Nov 1, 2000
21
US
Hello All,

I have a VB app that uses the following code to connect
to an Access 2000 database. I am using MDAC 2.6 and I distribute the MDAC installer in case the recipient doesn't
have it yet. This has been working great for several months
untill I ran into a user that has Access 97 installed on their machine. When the code executes on their machine the
system uses the access 97 driver to try and open the
applications database and I get an error stating that
Access97 can't open database because it is an unrecognized file format. I sent them a copy of the database converted from 2000 to 97 and it worked great but this is not a permanent solution. Is there a way to modify my connection string to include which registered driver version should be used?
Thanks You Very Much!


ConnectionString="Driver={Microsoft Access Driver (*.mdb)};"
 
Below is a connection string that I use with ADO and Access 2000. This might work for you:

"Provider=Microsoft.Jet.OLEDB.4.0; Data Source=c:\MyFolder\MyDatabase.mdb"

Hope this helps -- WB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top