国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 學院 > 開發設計 > 正文

CodeSimth

2019-11-17 01:25:37
字體:
來源:轉載
供稿:網友

CodeSimth - .Net Framework Data PRovider 可能沒有安裝。解決方法

今天想使用CodeSimth生成一個sqlite數據庫模板。當添加添加數據庫的時候發現:

.Net Framework Data Provider 可能沒有安裝。

下面找到官方的文檔說明:

SQLite Schema Provider

If you are trying to use the SQLite Schema Provider you may encounter the error message:'The System.Data.SQLite library is not installed on this computer'.This error can occur for two reasons:

  1. The System.Data.SQLite hasn't been installed on your machine.
  2. The System.Data.SQLite hasn't been properly configured.

InstallingSystem.Data.SQLite

Icon

CodeSmith Generator is compiled as AnyCPU. This means that Generator will run as a 64bit process when you launch Generator outside of Visual Studio. If you are generating from within Visual Studio (32bit process), then CodeSmith Generator libraries will run as a 32bit process.

This is very important to understand as it determines which Schema Provider dependencies are resolved atrun-time.

The first step is to ensure that you download and install the latest .NET Framework 4.0 version of System.Data.SQLite.

IconIf you are running a 64bit version of windows, please install both the 32bit and 64bit versions.IconYou can skip the following configuration steps if you install the legacy version ofSystem.Data.SQLite here.The older version configures itself by adding entries into your machine.config.

ConfiguringSystem.Data.SQLite

TheSQLite Schema Provider doesn't require a specific version of the SQLite managed libraries. This is because it usesDbProviderFactorieswhen interacting with SQLite. One must update all.NET Framework 4.0 machine.config's and add the SQLite provider to the DbProviderFactorieselement:

<system.data><DbProviderFactories><addname="SQLite Data Provider"invariant="System.Data.SQLite"description=".Net Framework Data Provider for SQLite"type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite"/></DbProviderFactories></system.data>

The .NET Framework 4.0 machine.config's can be found here:

  • %windir%/Microsoft.NET/Framework/v4.0.30319/Config/machine.config
  • %windir%/Microsoft.NET/Framework64/v4.0.30319/Config/machine.config
Next, you will need to copy the 64bit or 32bit SQLite assemblies that were installed via the System.Data.SQLite installer toCodeSmith Generatorsbin folder. This bin folder can be found in the location that you installed CodeSmith Generator to.

看不懂的話,按照下面的方法做:

1、下載System.Data.SQLite驅動;注意:根據自己的CPU選擇是32位還是64位的驅動。建議選擇4.0平臺以上的。我的是:sqlite-netFx40-setup-bundle-x64-2010-1.0.91.0.exe;

2、安裝完成后打開C:/Program Files/System.Data.SQLite/2010/GAC把里面的兩個dll復制到CodeSimth安裝目錄下的bin文件夾;

3、配置

  根據自己的CPU平臺打開下面路徑,【可能需要修改一下文件寫入的安全性,設置為Everyone就可以了,否則保存不了】

  • %windir%/Microsoft.NET/Framework/v4.0.30319/Config/machine.config
  • %windir%/Microsoft.NET/Framework64/v4.0.30319/Config/machine.config (我選擇的是這個)
  • 找到<system.data>節點添加下面的內容。
<system.data><DbProviderFactories><addname="SQLite Data Provider"invariant="System.Data.SQLite"description=".Net Framework Data Provider for SQLite"type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite"/></DbProviderFactories></system.data>

4、重啟CodeSimth就可以了。


發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 信阳市| 巴南区| 伽师县| 红桥区| 辽宁省| 肃南| 福安市| 漳平市| 上杭县| 惠来县| 资源县| 卢氏县| 云和县| 海淀区| 资溪县| 福清市| 陇川县| 永修县| 南昌市| 读书| 宝丰县| 建昌县| 海淀区| 黑龙江省| 泰宁县| 宁海县| 海宁市| 诏安县| 壤塘县| 麟游县| 龙山县| 宜黄县| 汨罗市| 舟山市| 叶城县| 奎屯市| 焉耆| 栖霞市| 五华县| 常德市| 革吉县|