简体   繁体   English

无法加载文件或程序集'System.Web.Mvc(1)'或其依赖项之一

[英]Could not load file or assembly 'System.Web.Mvc(1)' or one of its dependencies

The following error appeared after deploying the application to IIS, although it's NOT the first time to deploy this web application, but this is a new update to it! 将应用程序部署到IIS之后,出现以下错误,尽管这不是第一次部署此Web应用程序,但这是对其的新更新!

Could not load file or assembly 'System.Web.Mvc(1)' or one of its dependencies. 无法加载文件或程序集'System.Web.Mvc(1)'或其依赖项之一。 The located assembly's manifest definition does not match the assembly reference. 找到的程序集的清单定义与程序集引用不匹配。 (Exception from HRESULT: 0x80131040) (来自HRESULT的异常:0x80131040)

在此处输入图片说明

It looks like you tried to install the ASP.NET MVC dependency twice since you have System.Web.Mvc(1) instead of plain System.Web.Mvc , so please take note of that. 似乎您尝试两次安装ASP.NET MVC依赖项,因为您拥有System.Web.Mvc(1)而不是普通的System.Web.Mvc ,因此请注意这一点。 More than likely, that other assembly you are using is referencing the old dll, so make sure you have the right newVersion value under BindingRedirect in your Web.config file, as it should look something like this: 更可能的是,其他装配您正在使用引用旧的DLL,所以一定要确保你有合适的newVersion下值BindingRedirect在你Web.config文件,因为它应该是这个样子:

<runtime>
  <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
    <dependentAssembly>
      <assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35"/>
      <bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0"/>
    </dependentAssembly>
  </assemblyBinding>
</runtime>

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 无法加载文件或程序集 System.Web.Mvc 或其依赖项之一 - Could not load file or assembly System.Web.Mvc or one of its dependencies 找不到包含文档的“无法加载文件或程序集&#39;System.Web.Mvc&#39;或其依赖项之一” - Can't resolve “Could not load file or assembly 'System.Web.Mvc' or one of its dependencies” with documentation found 无法加载文件或程序集“System.Web.Mvc,Version = 3.0.0.0”或其依赖项之一 - Could not load file or assembly 'System.Web.Mvc, Version=3.0.0.0' or one of its dependencies 无法加载文件或程序集“System.Web.Mvc”或其依赖项之一。 定位的程序集的清单定义与程序集不匹配 - Could not load file or assembly 'System.Web.Mvc' or one of its dependencies. The located assembly's manifest definition does not match the assembly 无法加载文件或程序集&#39;System.Web.Mvc&#39;或其依赖项之一。 2个项目。 一次只能工作一个 - Could not load file or assembly 'System.Web.Mvc' or one of its dependencies. 2 projects. Only one will work at a time 无法在MVC 5中加载文件或程序集&#39;System.Web.Mvc&#39; - Could not load file or assembly 'System.Web.Mvc' in mvc 5 无法加载文件或程序集“ System.Web.MVC,版本4.0.0.0” - could not load file or assembly 'System.Web.MVC, version 4.0.0.0,' 无法加载文件或程序集System.Web.Mvc,版本= 5.2.3.0 - Could not load file or assembly System.Web.Mvc, Version=5.2.3.0 无法在单元测试中加载文件或程序集&#39;System.Web.Mvc - Could not load file or assembly 'System.Web.Mvc In Unit Test 无法加载文件或程序集System.Web.Mvc - Could not load file or assembly System.Web.Mvc
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM