What causes System.BadImageFormatException when constructing System.Data.SQLite.SQLiteConnection

好久不见. 提交于 2019-11-28 07:12:00

SqlLite contains unmanaged code, you can't run it on a 64-bit operating system unless you deploy the 64-bit version. Quick fix: Project + Properties, Build tab, Platform Target = x86.

Make sure you use correct assembly with respect to 32 and 64 bits.

I solved the problem by downloading a new version of the SQLite DLL via NuGet: http://gurustop.net/blog/2011/05/19/sqlite-database-nuget-package-common-problems-solved/

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!