Click here to Skip to main content
15,671,597 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi Everyone:
I looked up this error on the internet and I can't find an answer for my situation.

I have two VB.NET projects that use an MS Access 2010 database to retrieve information on how to place a control dynamically on the Form.

The DataEntry project works fine. I can connect to the MS Access database and the form functions as designed. I can read the data from the database and I don't get any errors.

The Uni_DE_Tool project uses the exact same MS Access database and code to retrieve the data, but I get the 'Microsoft.ACE.OLEDB.12.0' provider is not registered on the local machine error.

Both projects are on the same machine, so logic dictates that if one project works, so should the other. Both projects have the same Namespaces and resources included.

Can someone enlighten me as to why this happens? My initial guess would be I am missing some namespace or resource, but I double checked both projects and made sure the Imported Namespaces and Added resources are the same.

Maciej Los 20-Oct-13 15:36pm    
Check connection string!

1 solution

I found the answer.

1. Right click on your Project name.
2. Click on the Compile Tab
3. At the bottom of the page click on the button Advanced Compile Options.
4. On the Advanced Compiler Settings page on the Target CPU pull down menu select x86
5. Click OK

You should be able to connect to MS Access DBs using the Microsoft.ACE.OLEDB.12.0 provider.
Share this answer
Maciej Los 20-Oct-13 15:47pm    
OK. Mark this answer as a solution (green button) - formally to remove question from unanswered questions list ;)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900