0

Recently, I've been working on a project with Access database, but since the deployment would be on a XP computer, I tried changing the .NET Framework from 4.5.1 to 4.

Since then the connection fails to open, and continues to fail even tough I changed it back to 4.5.1.

con.ConnectionString = "Provider = Microsoft.ACE.OLEDB.12.0;Data Source = " + Localexe + @"/Database.accdb";
try
{
    con.Open();
}
catch (Exception x)
{

}

It says that:

provider 'Microsoft.ACE.OLEDB.12.0' could not be found on the local machine

I tried opening a new project and seeing if there were any References that got lost on the process but that didn't seem to work.

Erik A
  • 31,639
  • 12
  • 42
  • 67
Pedro Farina
  • 98
  • 1
  • 6
  • I guess you have to install Microsoft Access Database Engine? https://www.microsoft.com/en-in/download/details.aspx?id=13255 – Ram Nivas Dec 09 '16 at 12:23
  • You can see the [answer](http://stackoverflow.com/a/32760211/3637582). Maybe you can fix it with this. – tserdas Dec 09 '16 at 12:45
  • @tserdas I arealdy downloaded it, but it seems that since the 'Microsoft.ACE.OLEDB.12.0' is only avaible to 64x, when I changed the framwork it lost some part of the path. – Pedro Farina Dec 09 '16 at 12:59

1 Answers1

0

What is your OS and its bit? what is your access bit? x86 or x64? anyway pls try : DefaultAppPool and Classic .NET AppPool (find these path) - right click - 32bit app enable(true)...after this , right click and restart. I guess it works.

tserdas
  • 57
  • 7