title: Is it possible to use LoadLibrary from a dll in Borland C++ from a given path?
body: <p>I have a C++ dll which loads a C++ CLI library using LoadLibrary function as follows:</p>
  
  <pre><code>HMODULE myDLL = LoadLibrary("DLLtoBeLoaded.dll");
  </code></pre>
  
  <p>and this works.
  But I want my "DLLtoBeLoaded.dll" in a different directory(Different from the executable directory). So I tried:</p>
  
  <pre><code>HMODULE myDLL = LoadLibrary("C:\\DLLtoBeLoaded.dll");
  </code></pre>
  
  <p>This does not work. Although myDLL is not null after this but DLLtoBeLoaded.dll's constructor is not called.</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>MyDLL is not null because LoadLibrary is actually successful. But the reason why it did not seem to work was that the DLLtoBeLoaded.dll references some dlls which are also not in executable directory(The program works if I just copy referenced dlls in executable folder). Is it possible to keep the referenced dlls in different folder from executable?</p>