Workaround: The "microsoft.jet.oledb.4.0" provider is not registered on the local computer
In Windows 7 (32-bit) with the. NET developed Excel import datasheet feature, after testing everything is OK, site publishing moved to Windows Server 2008 (64-bit) on the unexpected, an error message, run the program, throw an exception: not registered on the local computer Microsoft.Jet.OLEDB.4.0 provider, engaged in long time, do not know what reason, and then searched a bit, only to find a solution to the problem is so simple:
One of the workarounds:Compile project specifies target platform for x86 is over, cannot be used with any CPU generation, Configuration Manager, platform, click any CPU tab, new-New platform->x86Solution Two:Set the application pool default properties/General/enable 32-bit application to true in the corresponding IIS application pool.
Operation Operation:
here's how to fix it:
method One: "Set Application Pool Default Properties"/"General"/"Enable 32-bit application", set to True. As shown in the following:
method Two: Build, Configuration Manager, platform, click any CPU tab, new-new platform->x86. As shown in the following: