The .NET Assembly “Incorrect Format” Error

If you get this error in a Windows Forms project… Look in your Project–>Properties (ALT+F7) and go to the “Build” tab. You’ll see the “Platform target” – If it’s set to “x64”, then make sure you reference the 64-bit Chilkat assembly. – If it’s set to “x86”, then make sure you reference the 32-bit Chilkat assembly. – If it’s set […]

.NET Assembly Incorrect Format Error

“Could not load file or assembly ‘ChilkatDotNet2, Version=9.3.0.0, Culture=neutral, PublicKeyToken=eb5fc1fc52ef09bd’ or one of its dependencies. An attempt was made to load a program with an incorrect format.” The “incorrect format” error is a 32-bit vs. 64-bit mismatch.  It means the application is trying to load a 64-bit .NET assembly into a 32-bit process,  or the reverse (a 32-bit assembly into […]

Incorrect Format Error when trying to load .NET Assembly

This Chilkat blog post explains the following error: “Could not load file or assembly ‘ChilkatDotNet2, Version=9.0.8.0, Culture=neutral, PublicKeyToken=eb5fc1fc52ef09bd’ or one of its dependencies. An attempt was made to load a program with an incorrect format.” When a DLL is loaded, it is mapped into the process’s address space. If the process is running in a 32-bit address space, the DLL […]