1

I'm working on a VB2008 project that references two Access databases using Provider=Microsoft.Jet.OLEDB.4.0;

It would seem if the user does not have MSOffice on their machine, the program crashes with a "XXX stopped working" on startup on Vista and Win7.

I thought that Windows had XP and above had Jet functionality built in? Does anyone know why this is happening? What are the correct project/publish/prerequisites required please?

TIA

user57087
  • 147
  • 2
  • 4
  • 9
  • What's the rest of the connection string? I didn't have any problem connecting to an Access database in Windows 7 without Office installed. – Guffa Jul 17 '09 at 11:48
  • It's in the app settings and set up through the wizards in VB. Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|\xxx.mdb – user57087 Jul 17 '09 at 12:10

1 Answers1

3

There is absolutely NO Jet support for x64 architectures. So the program will runtime error if you are running on an x64 proc and your application is compiling to AnyCPU.

Change the compile target of your application to x86 explicitly and your problems should go away...if I have correctly ID'ed the issue that is. If the failing machines are running x86 OSes then you'll have to look for another solution. But if the failing machines are running x64 OSes then I guarantee this is the problem.

Seth

Seth Spearman
  • 6,710
  • 16
  • 60
  • 105
  • THANK YOU Seth I think you may have hit the nail on the head. I shall investigate and report back. – user57087 Jul 17 '09 at 14:18
  • It did, thank you! It installed fine on Windows 7 after I made the change. I am using VB Express so had to manually add in the line of code into the Project Settings x86 Only problem now is that the ClickOnce deployment is messed up and the app thinks it is a different app entirely... sigh. Wonder if there is a way around this?? Thanks – user57087 Jul 26 '09 at 12:37