Archive: Ordinal not found error


I have compiled an installation that uses the DLLRegisterServer function, and it works fine with Windows 2000 SP1 machines (Mfc42.dll 6.0.8665.0), but when a client runs it on an NT 4.0 SP4 machine (Mfc42.dll 4.2.xxxx) they receive the following error when the install program tries to register a DLL:

Olemainthreadwndname:
Ordinal 6663 could not be located in the DLL Mfc42.dll

Is this because the Mfc42.dll is too old on the client's machine? I did not think this installer had a reference to the MFC, but mabye I'm wrong. Can anybody help? Thanks.


Saw this was posted two years ago. I've actually run into now. Is it from out of date MFC42 DLL?


If I remember correctly, the problem was an out of date Mfc42.dll. I was able to rename the old version, then copy the newer version from a Win2k box, then reboot the NT4 machine, and then it worked (I think). That was a while ago so I can't remember exactly how I resolved the issue.


Are you using the RegDLL command?


No I don't use RegDLL anywhere in my script. At least not to my knowledge. Could be it's hidden away in a macro or something but I doubt it.


So which command are you using to call DLLRegisterServer?


Correction, I used to call RegDLL to register a DLL but I no longer use that. I now only have a call to UnRegDLL to get rid of the DLL I was formerly registering. Could that cause the problem?


When installing an MFC application you should make sure the computer you're installing to has the right MFC version. IIRC Microsoft provide pre-built installers for MFC, so you can get one from MSDN and install it if the MFC dll version doesn't match your plug-in expectations.


Ok thanks Kichik, I'll do that.