How can I run .exe with a DLL in a separate directory?

I know that this has already been discussed somewhere here, but I did not find the question that I wanted, namely: I have a C ++ application that uses a lot (over 20-30) DLLs. In my Visual Studio 2010 project, I determined that .exe will be copied to ProjectDir (so that everything is neat and clear), but when .exe is only in ProjectDir, it cannot access the DLLs stored in bin.// any folder along with many other files.

Is it possible to somehow specify the DLL folder so that the application finds out where they are? (and in the folder folder <myapp>.exe.localdoes not work in my Windows 7)

+5
source share
2 answers

exe , .exe , . , dll, Windows, DLL , , DLL PATH, , .

, dll, dll, , (, HINSTANCE hDLL = LoadLibrary(L"C:\\mydll.DLL");) , -, dll ( , 2 ), (. HINSTANCE hDLL LoadLibrary("..\\dlls\\mydll.dll")

+2

All Articles