Page 1 of 1

Registering DLL

Posted: Wed Apr 24, 2019 6:11 am
by ktp
Hi,

have created an OLE object and would need to have it registered as part of the installation.

When I do it manually from an elevated command prompt in Windows 10, using the below command, it succeeds.

Code: Select all

regasm.exe  MY_TEST.dll


When doing from Installaware, I get the error code -11 and the dll doesn't get registered. Here is an extract from the installation script. I have even copied the regasm program to the target directory.

Code: Select all

Run program under UAC regasm.exe  MY_TEST.dll, startup in folder $TARGETDIR$


Tried also

Code: Select all

Register Library
and

Code: Select all

Register Assemble
, and both returned "OK", but didn't get the DLL registered, at least my application didn't recognise the OLE object, as it does when running the regasm manually.

What does error code -11 mean and is there a way to get a textual error message?
Any ideas on how to resolve this would be great.

Thanks,
ktp

Re: Registering DLL

Posted: Fri Oct 25, 2019 1:43 pm
by SteveDude
Registering DLL's can be sketchy at it's best and was even more tricky in the older days. What I've done on more than one occasion is skip all the register processes altogether and just write the registry information myself. Can be a hassle and a bit tricky sometimes, but it has never failed me.