故事:我的网站运行在System.Data.OraceClient(由于各种技术原因,我无法更改dll)。现在,我有一个第三方DLL集成到我的网站是32位。当我从Visual Studio运行时,一切都运行良好,但是当我将它发布到IIS时,它会引发上述错误。尝试加载Oracle客户端库丢弃BadImageFormatException IIS System.Data.OracleClient
现在解决办法是: 启用IIS应用程序池32位
当32位启用第三方DLL将开始工作,并System.Data.Oracle client fails with BadImageFormat exception
在IIS应用程序池禁用32位。
当32位被禁用时System.Data.OracleClient
将开始工作,并且第三方DLL将失败并出现以下错误。
Retrieving the COM class factory for component with CLSID {xxxxx} failed due to the following error: xxxxxx Class not registered
-- This class is registered. That is why it works when 32 bit is enabled.
现在,我处于一种情况,一次只能有一个DLL工作。有没有解决方法可以让我的System.Data.OracleClient在应用程序池中启用32Bit时运行,而无需将我的整个应用程序迁移到Oracle Data Access?
我只是在做它一个刺在这里,但...什么版本的Oracle客户端安装在Web服务器上(是完整的客户端或即时客户端)?它是32位还是64位? –
它来自4.5.1的.Net程序集。 DLL的版本是4.0,我相信它是64位。 – smilu