title: What might prevent a DLL from loading with LoadLibrary?
body: <p>I have a JD Edwards business function, which is written in Microsoft Visual C++ as a C module. I'm using LoadLibrary to access a third party DLL. In a standalone test program, the code runs just fine. When I run it from within JDE, LoadLibrary returns NULL and GetLastError returns 126, which means <code>The specified module could not be found</code> according to MSDN. I've tried putting in the full path to the DLL, and yes I've remembered to double up the \ characters in the path. No difference.</p>
  
  <p>I've checked to make sure there are no dependencies that would keep the DLL from loading; DUMPBIN /DEPENDENTS returns the following:</p>
  
  <pre><code>WSOCK32.dll
  USER32.dll
  GDI32.dll
  WINSPOOL.DRV
  ADVAPI32.dll
  KERNEL32.dll
  </code></pre>
  
  <p>These look like standard Windows DLLs, so I'm at a loss.</p>