我正在使用版本为1.0.115.5的System.Data.SQLite.Core。我尝试按照以下方式创建并打开SQLiteConnection。
string DatabaseName = GetDatabasePath();
var sqlite2 = new SQLiteConnection($"Data Source={DatabaseName}");
sqlite2.Open();
GetDatabasePath是一个函数,返回DB文件的完整路径。
我遇到了以下异常。
System.IO.FileNotFoundException
HResult=0x80070002
Message=Could not load file or assembly 'System.Data.SQLite.SEE.License, Version=1.0.115.5, Culture=neutral, PublicKeyToken=433d9874d0bb98c5, processorArchitecture=MSIL'. The system cannot find the file specified.
根据我的研究,System.Data.SQLite.SEE.License是SQLite加密扩展的一部分。如果您想为数据库创建密码,则会使用它。然而,我没有为数据库设置密码。为什么我会收到这个错误?