I need help!!!
I have added a COM wrapper to the DBX of a project that I am developing. It all worked fine on the computer that I am developing it on but when I tried to install the plugin on a different machine I cannot get the COM server to register.
Here are some of the details.
Developing for AutoCAD 2009,
Using ObjectARX 2009 VC++ 2005 SP1.
I tried to both register the COM at install time and at run time but I can't get either to work.
Install-time COM Registration:
I can't get it to register with "regsvr32.exe myDBX_COM.dbx". Either on the development machine (Win 7 x64) or the test machine (Win 7 x64). MyDBX_COM.dbx is installed in "c:\Program Files\Common Files\Autodesk Shared". It says that the module "myDBX_COM.dbx" failed to load. I used the dependency walker to see if I am missing any dlls and added the AutoCAD 2009 folder to the search path. It says I have an error opening MFC80U.DLL, VCOMP.DLL, GPSVC.DLL and IESHIMS.DLL. From what I understand the last two are delay-load and are not a problem. But I do not understand why the first two cannot be found. They are not missing directly from myDBX_COM.dbx but indirectly from ACDB17.DLL. But when I open that file in the dependency walker only GPSVC.DLL and IESHIMS.DLL are missing from it. I also tried moving my dbx file to the AutoCAD 2009 folder but still no change.
Run-time COM Registration:
When I run the plugin on the test computer it fails to register the COM server. The HRESSULT message from DLLRegisterServer is "Access is denied". When I run in Admin mode it succeeds, but on subsequent runs in normal mode I get the error message again. What is unusual is that it is able to register on the development computer whether or not I am in Admin mode at run time and I do not get any error messages.
If I could get run-time COM registration without having to run AutoCAD in Admin mode I would be happy with that but I would be most happy with figuring out how to get it to register at install-time.
I have read everything that I can find about this on the forums but I still can't figure it out.
Any thoughts would be very appreciated!!!
Solved! Go to Solution.
I read the article. It was very useful!!!!! It shed a lot of light on the issue for me! I changed the COM DBX to be un-manifested and I statically linked the ATL. This has definitely simplified everything for me! But I am still having problems registering the COM server. I will bullet point a few questions that I still don't understand.
Thank you Owen,
I have created a manuel registration of the COM server at install time like you suggested. It works great!!
Thanks so much! It feels like I've been beating my head against the wall on this one! So to finally get it figured out is fantastic. I thank you and my head thanks you!
I've added a more detailed explanation of "manual" registration in a blog post here:
Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register