我在项目中插入了app.config文件。 请帮我解决这个问题。
<?xml version="1.0"?>
<configuration>
<configSections>
</configSections>
<connectionStrings>
<add name="RConnString" connectionString="Data Source=C:\Users\user\Documents\Visual Studio 2010\Projects\Pathology lab\Pathology lab\bin\Debug\Pathology.sqlite"
providerName="System.Data.Sqlite" />
<add name="Pathology_lab.Properties.Settings.PathologyConnectionString"
connectionString="data source="C:\Users\user\Documents\Visual Studio 2010\Projects\Pathology lab\Pathology lab\bin\Debug\Pathology.sqlite;"
providerName="System.Data.SQLite" />
<add name="screen_shot.Properties.Settings.PathorecordConnectionString"
connectionString="data source="C:\Users\user\Desktop\screen shot\screen shot\bin\Debug\Pathorecord.db""
providerName="System.Data.SQLite" />
</connectionStrings>
<startup useLegacyV2RuntimeActivationPolicy="true">
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/>
</startup>
</configuration>
答案 0 :(得分:1)
尝试在| DataDirectory | /Databasename.db中编写连接字符串 并调用App.domain()方法
答案 1 :(得分:1)
尝试使用此连接字符串