title: Load two instances of the same DLL in Delphi
body: <p>Here's my problem: I would like to create two separate instances of the same DLL. </p>
  
  <p>The following doesn't work because Handle1 and Handle2 will get the same address</p>
  
  <pre><code>  Handle1 := LoadLibrary('mydll.dll');
    Handle2 := LoadLibrary('mydll.dll');
  </code></pre>
  
  <p>The following works, but I have to make a copy of the DLL and rename it to something else (which seems a bit silly)</p>
  
  <pre><code>  Handle1 := LoadLibrary('mydll.dll');
    Handle2 := LoadLibrary('mydll2.dll');
  </code></pre>
  
  <p>Is there a way to have only one DLL file, but load several instances of it?</p>