Page 1 of 1

BadImageFormatException

Posted: Tue Feb 19, 2019 11:30 pm
by Jack_2019
Hi
I have DGK 32 bit installed. When I try to start Curves sample I get this:

An unhandled exception of type 'System.BadImageFormatException' occurred in System.Windows.Forms.dll

Additional information: Could not load file or assembly 'Interop.KernCADnet, Version=1.3.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.

Any suggestions please?
Jack

Re: BadImageFormatException

Posted: Thu Feb 21, 2019 5:07 am
by Prashant Kande
Hello Jack
This happens if you select AnyCPU in Platform target on Build tab of project properties. It has to be either x64 or x86. This is because DGK is a native component. We are planning a pure .Net control in the near future where you would not need to commit this early
Regards
Prashant