I encountered a strange BadImageFormat Exception when trying to build the HelloWorld Demo.
My setup is VS2015 Debug x64, and before setting up this demo project I compiled the ChakraCore.dll by following the Wiki-tutorial.
This happened when I tried to run the console app:
This was very unusual because my Debug-Build is also x64 just like the ChakraCore.dll from the C++ project.
After some experimenting I changed the Platform Target from Any CPU to x64 in Project's Build-Properties:
Now everything worked as expected. :smile:
Maybe someone could put this info on the WIki? Don't want to unilaterally change it. Thanks!
Thanks for reporting this to us @brakmic !
Yes, the platform target of your app and the DLL platform need to match for this to work lol. I'll add a note on wiki.
Hi,
I encountered a strange BadImageFormat Exception when trying to build the HelloWorld Demo. My setup is VS2015 Debug x64, and before setting up this demo project I compiled the ChakraCore.dll by following the Wiki-tutorial.
This happened when I tried to run the console app:
This was very unusual because my Debug-Build is also x64 just like the ChakraCore.dll from the C++ project.
After some experimenting I changed the Platform Target from Any CPU to x64 in Project's Build-Properties:
Now everything worked as expected. :smile:
Maybe someone could put this info on the WIki? Don't want to unilaterally change it. Thanks!
Regards, Harris