VS2012以常規(guī)方式創(chuàng)建一ASP.NET MVC internet 項(xiàng)目。創(chuàng)建后F5啟動(dòng)項(xiàng)目,遇一錯(cuò)誤:
未能加載文件或程序集“MySQL.Web.v20, Version=6.9.4.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d”或它的某一個(gè)依賴項(xiàng)。系統(tǒng)找不到指定的文件。

解決方案:將C:/Windows/Microsoft.NET/Framework/v4.0.30319/Config/machine.config文件中的MySql.Web.v20替換為MySql.Web。特別注意:修改保存該文件,需以Administrator身份打開(kāi)該文件。
參考信息:
machine.config
The machine configuration file, Machine.config, contains settings that apply to an entire computer. This file is located in the %runtime install path%/Config directory. Machine.config contains configuration settings for machine-wide assembly binding, built-inremoting channels, and ASP.NET.
https://msdn.microsoft.com/en-us/library/ms229697(v=vs.90).aspx
與傳統(tǒng)的ASP不同的是,ASP.NET不是運(yùn)行在IIS的地址空間,而是有自己的進(jìn)程:aspnet_wp.exe。該進(jìn)程可以通過(guò)xml配置文件machine.config進(jìn)行配置。
http://www.survivalescaperooms.com/chenlulouis/archive/2010/05/26/1744261.html
新聞熱點(diǎn)
疑難解答
圖片精選
網(wǎng)友關(guān)注