Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Distilling your problem, I gather:</p> <ul> <li><p>You are able to load Xerces and Xalan individually, but not the test.dll file (which references the other dlls)</p></li> <li><p>You may be misled by the value <code>GetLastError()</code> returns when loading either Xerces or Xalan</p></li> </ul> <p>Remember that you must call <a href="http://msdn.microsoft.com/en-us/library/ms679360%28VS.85%29.aspx" rel="nofollow noreferrer"><code>GetLastError()</code></a> immediately after the <code>LoadLibrary</code> call: From MSDN docs:</p> <blockquote> <p>You should call the GetLastError function immediately when a function's return value indicates that such a call will return useful data. That is because some functions call SetLastError with a zero when they succeed, wiping out the error code set by the most recently failed function.</p> </blockquote> <p>This is most probably a dependency/path resolution issue (i.e. <code>LoadLibrary</code> can't find the requested image). So, you have two options:</p> <ul> <li><p>Does test.dll/Xerces/Xalan have other dependencies that you have not copied to your executable's folder?</p></li> <li><p>Put the dll in Windows\System32 folder and try again. If this works, then you can be sure you had hit a path problem. Read the MSDN page on <a href="http://msdn.microsoft.com/en-us/library/ms684175%28VS.85%29.aspx" rel="nofollow noreferrer"><code>LoadLibrary</code></a> -- it's a bit confusing but has some details that's easy to leave out.</p></li> <li><p>Use <code>GetCurrentDirectory</code> and <code>SetCurrentDirectory</code> to switch to and from the application's executing folder and the dll's residing folder</p></li> <li><p>Specify the full path to the dll in the call to <code>LoadLibrary</code>. You may face issues if the path name contains whitespace (this I recall from memory, please check with MSDN).</p></li> <li><p>Once done, be a good citizen and call <code>FreeLibrary</code>!</p></li> </ul>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload