ASP .NET Web窗体:无法加载文件或程序'System.Web.WebPages.Deployment,版本= 2.0.0.0 [英] ASP .NET Web Forms: Could not load file or assembly 'System.Web.WebPages.Deployment, Version=2.0.0.0
问题描述
我把我现有的ASP.NET Web站点和Web应用程序到一个新的服务器,我得到了以下错误:
I moved my existing ASP .NET web sites and web applications to a new server, and I'm getting the following error:
无法加载文件或程序集System.Web.WebPages.Deployment,
版本= 2.0.0.0,文化=中性公钥= 31bf3856ad364e35'或
它的一个依赖。该系统找不到指定的文件。
Could not load file or assembly 'System.Web.WebPages.Deployment, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
我位于我的电脑上本次大会,并将其复制到我的网站的bin文件夹。它提供了一个新的错误:
I located this assembly on my computer, and copied it to the BIN folder of my web site. It gives a new error:
无法加载文件或程序集System.Web.WebPages.Deployment,
版本= 1.0.0.0,文化=中性公钥= 31bf3856ad364e35'或
它的一个依赖。在位于集清单定义
不匹配的程序集引用。 (从HRESULT异常:
0x80131040)
Could not load file or assembly 'System.Web.WebPages.Deployment, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
这是否意味着ASP .NET未正确安装在服务器上?我该如何去修复呢?我还注意到,大会是在我的电脑上present某处程序文件(x86)/微软ASP.NET
文件夹中。但是,程序文件(x86)/微软ASP.NET
文件夹不存在于服务器上。
Does this mean ASP .NET is not properly installed on the server machine? How do I go about fixing this? I also noticed that the assembly is present on my computer somewhere in the Program Files (x86)/Microsoft ASP.NET
folder. However, the Program Files (x86)/Microsoft ASP.NET
folder does not exist on the server.
推荐答案
解决方案:我安装了ASP.NET的Web页和服务器上的ASP.NET MVC 4。这种安装缺少的组件和创建中缺少的文件夹。
Solution: I installed both ASP .NET Web Pages and ASP.NET MVC 4 on the server. This installed the missing assemblies and created the folders that were missing.
这篇关于ASP .NET Web窗体:无法加载文件或程序'System.Web.WebPages.Deployment,版本= 2.0.0.0的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!