c# - 'Microsoft.Data.Sqile.SQliteConnection' 的类型初始化程序引发异常 C#
问题描述
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
************** Exception Text **************
System.TypeInitializationException: The type initializer for 'Microsoft.Data.Sqlite.SqliteConnection' threw an exception. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Exception: Library e_sqlite3 not found
at SQLitePCL.NativeLibrary.Load(String libraryName, Assembly assy, Int32 flags)
at SQLitePCL.Batteries_V2.MakeDynamic(String name, Int32 flags)
at SQLitePCL.Batteries_V2.DoDynamic_cdecl(String name, Int32 flags)
at SQLitePCL.Batteries_V2.Init()
--- End of inner exception stack trace
当我在执行应用程序时创建项目的设置文件时收到此消息。但是当我在 Visual Studio 中调试它时,它运行良好并且没有任何问题。
解决方案
推荐阅读
- sql-server - 如何解决以下 SQL 查询?
- php - 来自 S3 存储桶的流式视频无法在 Safari 浏览器上运行
- javascript - 将 JavaScript JSON 对象与匹配的参数合并
- android - Seek Bar Preference 不更新其值
- javascript - 为什么我不能通过 JS 函数更改我的内部 HTML?
- java - 在我自己的单链表实现中插入数据
- go - gobuffalo/packr 如何(为什么)在构建时运行?
- javascript - 使用 ES6 解构赋值语法重新赋值变量
- openpyxl - openpyxl 删除行并更新excel文件
- c++ - d3d9 createdevice在alt选项卡后获取vtable黑屏