1

我尝试在管理员 cmd 中运行 aspnet_regiis.exe -ir 但没有运气。

有任何想法吗?

C:\Windows\Microsoft.NET\Framework64\v4.0.30319>aspnet_regiis.exe -ir

Microsoft (R) ASP.NET RegIIS 4.0.30319.17929 管理实用程序,用于在本地计算机上安装和卸载 ASP.NET。版权所有 (C) 微软公司。版权所有。在不更改现有 Web 应用程序的情况下开始安装 ASP.NET (4.0.30319.17929) 以使用此版本的 ASP.Net。此版本的操作系统不支持此选项。管理员应该使用“打开/关闭 Windows 功能”对话框、服务器管理器管理工具或 dism.exe 命令行工具来安装/卸载带有 IIS8 的 ASP.NET 4.5。有关详细信息,请参阅 http://go.microsoft.com/fwlink/?LinkID=216771。已完成安装 ASP.NET (4.0.30319.17929) 而不更改现有 Web 应用程序以使用此版本的 ASP.Net。

关于安装/卸载 ASP.NET 4.5 的所有这些可怕的讨论是什么?

4

4 回答 4

4

我在 Windows Server 2012 上的解决方案是:

  1. 在 IIS 中,打开模块,删除 ServiceModel 模块。
  2. 在 IIS 中,打开处理程序,删除 svc-Integrated 处理程序。
  3. 重新启动 IIS

更多信息:http: //www.codeproject.com/Articles/613812/Solve-IIS-8-Error-Could-not-load-type-System-Servi

造成这种情况的原因是我在设置 IIS 和 .NET 4.5 之后启用了 WCF 服务。这导致我在服务器上的所有应用程序都失败了。

在完成上述步骤以使除 WCF 之外的所有内容都恢复并运行之后,我仍然需要 WCF 才能工作。为此,我进入“打开和关闭 Windows 功能”并启用 .NET Framework 4.5 功能 -> WCF 服务 -> HTTP 激活

于 2013-07-03T18:20:10.767 回答
1

aspnet_regiis 在 IIS8 中已弃用。当我们安装 IIS(ASP .NET 4.5 和其他组件)时,asp .net 会自动注册。我们不需要手动注册它。

您能简要说明您面临的问题吗?

于 2013-03-09T21:28:27.730 回答
0

从管理命令提示符运行以下命令:dism /online /enable-feature /featurename:IIS-ASPNET45

对于 Windows 8 客户端计算机,在“Internet 信息服务 -> 万维网服务 -> 应用程序开发功能 -> ASP.NET 4.5”下的“打开/关闭 Windows 功能”中打开“IIS-ASPNET45”。

参考: http: //support.microsoft.com/kb/2736284

于 2013-05-28T19:10:29.947 回答
0

I was facing the same issue as described above. It didn't work even after running following command
dism /online /enable-feature /featurename:IIS-ASPNET45
The solution for me was to install patch to VS 2010 SP1.
Just to give the background I have Windows 10 and VS 2010 SP1 and was facing issue when running a ASP.Net 4.6 site.
Following are links for Visual Studio versions:-
VS 2010 SP1 => https://support.microsoft.com/en-us/help/3002340/unexpected-dialog-box-appears-when-you-open-projects-in-visual-studio
VS 2012 => https://support.microsoft.com/en-us/help/3002339/unexpected-dialog-box-appears-when-you-open-projects-in-visual-studio VS

于 2018-01-21T04:56:18.597 回答