Search code examples
visual-studio-2005dllregistration

Unable to register dll using regsvr32


My project generates a dll and when build in Debug mode the dll gets registered automatically by Visual Studio 2005. But when I try to register the same dll in command prompt using "regsvr32" I'm unable to register. I get the following error,

The module ".." failed to load. Make sure the binary is stored at specified path or debug it to check problems with the binary or dependent .DLL files.

But I have all the dependent dlls in place. What could be the reason for this issue.?

I tried registering and unregistering the dll using the following command,

regsvr32 dll_name.dll

regsvr32 /u dll_name.dll


Solution

  • The DLL might link to another DLL which isn't in the path when running regsvr32 from the command line.