views:

531

answers:

2

Hey gang,

I've having a problem with a VBScript connecting to an access MDB Database. My platform is Vista64, but the majority of resources out there are for ASP/IIS7.

Quite simply, I can't get it to connect. I'm getting the following error: 800A0E7A - "Provider cannot be found. It may not be properly installed"

My code is:

Set conn = CreateObject("ADODB.Connection")
strConnect = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\database.MDB"
conn.Open strConnect

So far I have ran %WINDIR%\System32\odbcad32.exe to try to configure the Driver in 32bit mode, but it hasn't done the trick. Any suggestions would be greatly appreciated

Just as an addition, I'm trying to get this .vbs script to run by double clicking and letting it do it's thing. This code isn't embedded into another lang/script.

A: 

This thread seems to explain your problem exactly:

http://social.msdn.microsoft.com/Forums/en-US/adodotnetdataproviders/thread/45aa44dd-0e6f-42e5-a9d6-9be5c5c8fcd1

Good luck.

HM2K
Keep in mind that Office 2010 will have a 64-bit version and that there's a 64-bit version of Jet/ACE in beta that is also downloadable. Others on SO have used it successfully to avoid having to compile as x86.
David-W-Fenton
A: 

Is C:\WINDOWS\system32\msjetoledb40.dll present on your machine?

Also try creating a file named test.udl and launching it. Does the Microsoft.Jet.OLEDB.4.0 provider appear in the provider list?

dudeNumber4
C:\WINDOWS\system32\msjetoledb40.dll is not on the machineand Microsoft.Jet.OLEDB.4.0 does not appear in the Provider list
Perma
dudeNumber4
It's 64-bit Windows.
David-W-Fenton