问题描述
在我们的Xamarin Android项目中,我们正在尝试从sqlite-net转换为正式的sqlite-net-pcl软件包.
On our Xamarin Android project we are trying to switch from sqlite-net to official sqlite-net-pcl package.
但是在创建新的SQLiteConnection时进行此切换之后,出现以下异常:
However after this switch when creating a new SQLiteConnection I am getting following exception:
完全例外:
在日志中,我可以看到以下信息:
In the log I can see following info:
很明显出了什么问题: System.DllNotFoundException:e_sqlite3 ,但是我找不到任何相关信息可以解决此问题.
It's obvious what's wrong: System.DllNotFoundException: e_sqlite3 however I can't find any relevant info that would lead to solving this problem.
我检查了我的nuget软件包,它们似乎都已正确安装.
I checked my nuget packages and they all seem to be correctly installed.
我检查了包裹的位置,并且都正确无误.非常不确定原因可能在哪里.
I checked the package location and it is all correct. Very unsure where the cause might be.
在这里向软件包的作者报告: https://github.com/praeclarum/sqlite-net/issues/478
Reported to the author of the package in here:https://github.com/praeclarum/sqlite-net/issues/478
推荐答案
nuget包也必须安装在我们的主要droid应用项目中.如果将它安装在不是应用程序启动项目的解决方案项目中,则会产生这些问题.
The nuget package had to be installed in our main droid app project as well. If it is installed in a solution project which is not the app start project then it creates these problems.
这篇关于Android-'SQLite.SQLiteConnection'的类型初始值设定项引发了异常.--->System.DllNotFoundException:e_sqlite3的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!