title: On some computers application can't load sqlite dll file
body: <p>I wrote an application that uses sqlite and it works great on <strong>most</strong> of the systems. It is written in C#, and the only non-framework assembly is sqlite, which is included by System.Data.SQLite.dll .</p>
  
  <p>I deploy it the same way on all of the machines (copy pasting the exe file, the database file and the System.Data.SQLite file). It works great for all my PC's and most of the PC's I've tried. </p>
  
  <p>But then I've got reports that for some people it throws the following exception:</p>
  
  <blockquote>
    <p>Could not load file or assembly
    'System.Data.SQLite, Version=1.0.65.0,
    Culture=neutral,
    PublicKeyToken=db937bc2d44ff139' or
    one of its dependencies. An attempt
    was made to load a program with an
    incorrect format.</p>
  </blockquote>
  
  <p>Now I've made sure the dll file is in the same folder than the application exe file. It's the same dll, with the same version as stated in the exception message above. </p>
  
  <p>I was really confused by this, so I created a fresh virtual machine, installed windows 7 professional on it, and just copy pasted the files, and the thing worked. So if it works on a fresh windows, I can't imagine what the other PC's could be missing...</p>
  
  <p>Note: Two of those machines where the project throws the exception are also running windows 7 proffesional.</p>
  
  <p>I would really appreciate any help on this, because I'm fresh out of ideas...</p>