I run:

regsvr32 somefile.dll

There is a long delay (approx. 1 minute) and then a warning dialog pops up that says:

LoadLibrary("somefile.dll") failed.
GetLastError returns 0x0000007e.

The DLL is in my current directory. I have tried multiple DLLs and they all give me the same error.

link|improve this question
feedback

3 Answers

up vote 1 down vote accepted

The problem ended up being that I had an old version of C:\windows\system32\regsvr32.exe. I got a new version of the executable from one of the network admins and that solved my problem.

link|improve this answer
feedback

From Microsoft http://support.microsoft.com/kb/238265 , about the 0x0000007e error code when registering a specific DLL

This behavior occurs because the Olemsg32.dll and Cdo.dll files are being called from the wrong installation point.

see if you can apply the fixes they suggest to your file, and you have to get administrative rights.

link|improve this answer
feedback

I discovered that the DLL that I was trying to register required that an additional DLL (mvscrtd.dll) had to be present in the system32 directory. I used the "Process Monitor" utility from Sysinternals to capture regsvr32 activity, and discovered a reference to the missing file.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.