ASP.NET MVC - 启动创建项目,未能加载错误

VS2012以常规方式创建一ASP.NET MVC internet 项目。创建后F5启动项目,遇一错误:

未能加载文件或程序集“MySql.Web.v20, Version=6.9.4.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d”或它的某一个依赖项。系统找不到指定的文件。

解决方案:将C:\Windows\Microsoft.NET\Framework\v4.0.30319\Config\machine.config文件中的MySql.Web.v20替换为MySql.Web。特别注意:修改保存该文件,需以Administrator身份打开该文件。

 

参考信息

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-in remoting channels, and ASP.NET.

https://msdn.microsoft.com/en-us/library/ms229697(v=vs.90).aspx

与传统的ASP不同的是,ASP.NET不是运行在IIS的地址空间,而是有自己的进程:aspnet_wp.exe。该进程可以通过XML配置文件machine.config进行配置。

http://www.cnblogs.com/chenlulouis/archive/2010/05/26/1744261.html

posted on 2015-06-02 22:12  iSun  阅读(631)  评论(0编辑  收藏  举报