I leave it to you because I am totally desperate.
I am using Microsoft.Jet.Oledb.4.0 to read my excel files, it works fine on my pc but when I put the application on my server (Windows Server 2012 R2) I get The 'Microsoft.Jet error. OLEDB.4.0 'provider is not registered on the local machine. By doing research on the Internet I could see that the application had to be build correctly compared to the server but nothing helped I tried in x64 and x86 and I still have the error (i have also tested Jet.Oledb.12.0 but still nothing). there is my code :
if (Path.GetExtension(path).ToUpper() == ".XLS")
{ //&& Environment.Is64BitOperatingSystem == false) {
//Connectionstring for excel v8.0
Console.WriteLine("Jet.OLEDB.4.0");
connString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + path + ";Extended Properties=Excel 8.0";
}
else
{
//Connectionstring fo excel v12.0
Console.WriteLine("Jet.OLEDB.12.0");
connString = "Provider=Microsoft.Jet.OLEDB.12.0;Data Source=" + path + ";Extended Properties=Excel 12.0";
}
There is the installation on the server :
Do you have an idea ? Thank's in adavance ;)