LoadLibrary can fail if the DLL is not in the specified path, or if the
specified path is incorrect. LoadLibrary can also fail if one of the
dependencies of the DLL that you are trying to load is not met; in other
words, if a dependent DLL is not present or is not in the specified path.
1.) If the dll has dependencies or is dependent on others, then it's
important to replace with the same version.
2.) If the dll exports the DLLRegisterServer, DllUnregisterServer functions
then it's best to unregister
regsvr32.exe /u "PathToDLL"
then after replacement
regsvr32.exe "PathToDLL"
INFO: How Regsvr32.exe Registers and Unregisters COM DLLs
http://support.microsoft.com/default.aspx?kbid=207132
Explanation of Regsvr32 Usage and Error Messages
http://support.microsoft.com/default.aspx?kbid=249873
You can run depends.exe against the DLL to check dependencies
You'll find depends.exe within
\SUPPORT\TOOLS\SUPPORT.CAB
--
Regards,
Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect
:
| regsvr32 C:\WINDOWS\system32\imgedit.ocx
| I get message LoadLibrary(" C:\WINDOWS\system32\imgedit.ocx") failed
| The specified module could not be found.
|
| This module I copied from windows2000 to XP
|
| Why do I get this message ???