Click here to Skip to main content
15,921,531 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi Team,

I have converted COM dlls in VS6.0 to VS2010. while debugging the COM dll code by giving C# GUI as the executable. Getting the following Exception.

"Retrieving the COM class factory for component with CLSID {uuid...} failed due to the following error: 80040154 Class not registered (Exception from HRESULT 0x80040154 REGDB_E_CLASSNOTREG));"

This was coming when calling constructor of the class in SLCOREINTERFACELib
objCoreinterface = new SerCoreInterfce();
where objCoreinterface is null and jumping to the above exception

When i try to register the COM dll using regsvr32 is giving Dll register successful. But i could not able to see the entries in REGEDIT.

How do i solve this issue. Is there any possibility that i can delete all the references to the COM dll in Registry and re-register again.Will that solve the issue?

Your quick help will be appreciated.

Thanks.
Posted
Updated 24-Sep-12 3:56am
v2

1 solution

Try setting Target Platform to x86:
In VS - project properties - in the Build tab - platform target =X86
 
Share this answer
 
Comments
Member 8132177 25-Sep-12 1:46am    
Thank you for the information but My PC is windows XP 32 bit. I have the Linker-Advanced -Target Machine set to X86 platform. I have checked the configuration manager setting where I have selected Win32 for build option. But still it is not working. Looking for some more suggestions.
While building I am getting the following output
InitializeBuildStatus:
Creating ".\ReleaseUMinDependency\SLCoreInterface.unsuccessfulbuild" because "AlwaysCreate" was specified.

but at the end

Build succeeded.

Time Elapsed 00:00:36.21
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========

Will that cause any problem registering the dlls?

When i checked the Registry in REGEDIT : I could not find Inprocserver23/PROGID /TypeLIb details for this COM dll.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900