RCIX
RCIX

Reputation: 39437

BadImageFormatException when attempting to use LuaInterface

I imported LuaInterface into a console project, referenced it, and wrote a small test script. When i run it, i get this:

Could not load file or assembly 'LuaInterface, Version=2.0.0.16708, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.

Forgive me for being a newbie or something, but i can't figure out what it means. What am i supposed to do?

Upvotes: 3

Views: 1420

Answers (1)

Nathan Baulch
Nathan Baulch

Reputation: 20683

Are you running on a 64-bit operating system?

If you are then you'll need to either get an x64 build of LuaInterface or set the platform target of your console project to x86.

Build properties screenshot

You can read up on the platform target option here: http://visualstudiohacks.com/articles/visual-studio-net-platform-target-explained/

Upvotes: 8

Related Questions