標籤:
VS 2012預設是不帶的SQLite的Data Provider,所以無法直接在VS 2012裡管理SQLite的資料庫,自然也不能在VS裡像SQL Server那樣直接產生Entity Framework的model類了。SQLite團隊為瞭解決這個問題,在SQLite的安裝包裡把用於VS2012的Data Provider給打包進去了。但是擼主卻失敗了無數次才找到正確把SQLite整合到VS裡的方法,記錄如下,分享給有需要的童鞋。
1,首先從http://system.data.sqlite.org/index.html/doc/trunk/www/downloads.wiki下載SQLite安裝包。這個頁面安裝包非常多,一下子就會看眼花繚亂。需要注意的是只有32位的安裝包才會能把SQLite的Data Provider加到VS Designer裡。如果你已經看的眼花繚亂,一個簡單的方法就是搜尋右邊描述裡有顯示如下黑體語句的This is the only setup package that is capable of installing the design-time components for Visual Studio 2012的安裝包,直接下載安裝就行。擼主這次下載到的檔案名稱是sqlite-netFx45-setup-bundle-x86-2012-1.0.93.0.exe。
2,安裝的時候一定不要用Full Installation,要選擇Custom Installation,然後只選擇Core Component(包括它裡面的2個) 以及Visual Studio Designer Component。
3,點擊下一步,在Install Designer For Visual Studio 2012前面打鉤
4,安裝完畢後,重啟VS 2012後就應該能看到SQLite Data Provider的選項了。
2014.8.10更新,Visual Studio 2013裡啟用SQLite Data Provider的步驟是一樣的,就是下載安裝包的時候要選擇This is the only setup package that is capable of installing the design-time components for Visual Studio 2013左邊的那個安裝包。
轉載http://www.cnblogs.com/ggbbeyou/p/4319756.html
VS2012,VS2013啟用SQLite的Data Provider介面顯示