Hi,
I have got on a dev machine project which has a c# file which calls a c++ dll.
This works fine . So nothing wrong with the way I am calling the c++ dll or anything wrong with the c# file.
However , I need to move to a new dev machine.
I have simply copied the project over (i.e. copied the project folder from ../Visual Studio 2005/Projects/). The c# prgram works fine. BUT when calling the c++ dll it is unable to locate it!
Error is:
- [System.DllNotFoundException] {"Unable to load DLL 'facedetect.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)"} System.DllNotFoundExceptionThe dll is in the same folder (i.e. bin/debug) as the c# exe.
Nothing wrong with the c# program, nothing wrong with the c++ dll, nothing wrong with the way I'm calling c++ - this has all been tested. ...
Any other ideas
Ash

DLL Import and Migrating Projects
Jamin Mace
You have to register the DLL that is writen in C++ on the other machines.
Or there is a problem and this exception is thrown within the DLL you are trying to load and the exception bubbles up.
Jeremy51
I have a question on this topic - I'm new to C# and writing a web service. I'm trying to call an existing C++ DLL with C#, and keep getting System.DllNotFoundException. What folder does such a project expect the DLLs to be located in
Thanks.
ansaria
spnz
The problem was that there was a dependancy of the dll missing.
Cheers
Ash
Rieekan