title: Sybase driver error in 64 bit windows server
body: <p>I have a console application which works perfectly in 32 bit machine. But I'm having problem running the executable in 64 bit windows server. The error message I get is:</p>
  
  <blockquote>
    <p>The type initializer for "Sybase.Data.AseClient1.AseConnection" threw an exception. System.BadImageFormatException. An attempt was made to load a program with incorrect format.  at Sybase.Data.AseClient.Unmanaged.AseGetDriverVersion at Sybase.Data.Aseclient1.AseConnection.CheckVersion(). </p>
  </blockquote>
  
  <p>Has anyone seen this error? </p>
  
  <p><strong>Update:</strong> After compiling in X86, I get:</p>
  
  <blockquote>
    <p>Major version mismatch sybdrvado20.dll. Expecting major version '2'. Loaded version 1 at Sybase.Data.AseClient1.AseConnection.CheckVerison. </p>
  </blockquote>
  
  <p>Please note that the server has latest Sybase version.</p>