BadImageFormatException exception while trying to use LuaInterface

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

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 a newbie or something like that, but I can't understand what that means. What should I do?

+3
source share
1 answer

Do you work on a 64-bit operating system?

If you are then you need to either get the x64 LuaInterface assembly, or install the platform target of your console project on x86.

Build properties screenshot

: http://visualstudiohacks.com/articles/visual-studio-net-platform-target-explained/

+8

Source: https://habr.com/ru/post/1716197/


All Articles