title: Tips to help debug "Could not load file or assembly X or one of its dependencies"
body: <p>I'm looking for tips/suggestions/insights to help debug an on application load issue; <em>Could not load file or assembly</em>...</p>
  
  <p>The solution/project where I'm experiencing this issue is a conversion from a working copy in Visual Studio 2008 to the Visual Studio 2010 Release Candidate. The conversion process appeared to be successful, and all the solution projects are set to <em>Framework 4</em>.</p>
  
  <p>The exception is on a 3rd party component (a graphics processing library), but any answers could possibly help others with any troublesome DLL.</p>
  
  <blockquote>
    <p>Could not load file or assembly 'Aurigma.GraphicsMill.DLL' or one of its dependencies.  is not a valid Win32 application. (Exception from HRESULT: 0x800700C1)</p>
  </blockquote>
  
  <p>What's confusing about this exception is the additional text: <em>is not a valid Win32 application</em>. </p>
  
  <p>The full exception stack trace is up on <a href="http://pastebin.com/f5c33d1e0" rel="noreferrer">PasteBin</a>, but doesn't seem to shed much more light on the issue...</p>
  
  <p>What I have tried so far with no success:</p>
  
  <ol>
  <li>Simple clean, rebuild, restart combinations of Visual Studio 2010 RC.</li>
  <li>Removing and re-adding the DLL in question.</li>
  <li>Toggling "copy local" to true and false on the DLL in question.</li>
  <li>Confirming that after a "successful build" the DLL in question appears in the bin\debug folder.</li>
  <li>Checking for any unnecessary references to the DLL in question (none found).</li>
  <li>The associated licence file for the DLL in question is in the same directory with it.</li>
  </ol>
  
  <p>I've also had no luck with it hitting any debugger breakpoints on application load.</p>