Reputation: 2333
I have an ASP.NET 3.5 application where I am using an ActiveX control. When I try to run the website from Visual Studio 2008 using built-in web server it is working like a charm.
When I publish the same code to IIS I get the following error:
Retrieving the COM class factory for component with CLSID {ADAACEC8-D9F2-4E05-A5F3-D29E5C9C82F9} failed due to the following error: 80040154.
How can I fix this issue??
Upvotes: 2
Views: 676
Reputation: 3458
To build on what Kev and Sheng Jiang 蒋晟 have said, it sounds like the COM component isn't registered properly or is having a bitness issue.
Is the activex DLL written in C++/compiled specifically for 32 or 64 bit/ or use DLLs that are specifically 32 or 64 bit?
If the ActiveX dll can run in either an x86 or x64 process, then it might not be registered correctly.
C:\Windows\system32\regsvr32.exe
. C:\Windows\syswow64\regsvr32.exe
Upvotes: 0
Reputation: 15261
could be a number of reasons. http://support.microsoft.com/kb/257757 listed some of them. In addition to the problems mentioned in the article, there could be some DLL loading issue, such as the COM DLL may not support the CPU architecture of the application pool, or one of its dependencies can not be found or can not be accessed.
Upvotes: 1
Reputation: 119806
The HRESULT in the error message (80040154) usually means 'Class not Registered'.
Try re-registering the component:
regsvr32.exe MyActiveX.dll /u
regsvr32.exe MyActiveX.dll
Upvotes: 1
Reputation: 12552
Just a guess. You can add to you web.config file
<identity impersonate="true" userName="Domain\MyUsername" password="MyPassword"/>
Once i had a similar problem and this solved it.
Upvotes: 0