System.DLLNotFoundException when the DLL exists

4

I am getting the following error when we load up a DLL in our program that throws the following error:

Unable to load DLL 'xxx.dll': The specified procedure could not be found. (Exception from HRESULT: 0x8007007F)

This doesn't make sense to me because the DLL exists and is built into our installer every time we make a change to our code. This DLL has not changed in months and this just started happening about a week ago from our newly installed copies. Any ideas? The project in question is an unmanaged C++ project that gets called from a .NET 3.5 app.

c++
.net-3.5
dllnotfoundexception

2 Answers

4

Probably one of xxx.dll's dependencies is not being found. You can inspect its dependencies using DUMPBIN /dependents xxx.dll, and intuit some additional information by using Dependency Walker to see which ones might not be present or unfindable on the system under test.

answered on Stack Overflow May 2, 2011 by Andy Finkenstadt • edited Aug 31, 2011 by LeopardSkinPillBoxHat
3

The error isn't saying that the DLL doesn't exist; it's saying that the DLL is missing the procedure call you're trying to make. This most likely means there is another DLL with the same file name earlier in the search path, that's an older version.

Are you installing the DLL into the same folder as the calling application?

answered on Stack Overflow May 2, 2011 by Michael Edenfield

User contributions licensed under CC BY-SA 3.0