HTTP错误404.17-找不到-.NET-IIS 10

问题描述 投票:0回答:1

这是我第一次在ASP.NET中发布Web表单项目。我可能遇到了http错误,但是我不明白这一点。我的IIS版本是10.0

HTTP Error 404.17 - Not Found
The requested content appears to be script and will not be served by the static file handler.

我在互联网上看到很多解决方案,其中有一个共同点,并且正在运行中

C:\Windows\Microsoft.NET\Framework\v4.0.30319>aspnet_regiis -i in cmd.

但是我确实收到此错误:

Microsoft (R) ASP.NET RegIIS version 4.0.30319.0
Administration utility to install and uninstall ASP.NET on the local machine.
Copyright (C) Microsoft Corporation.  All rights reserved.
Start installing ASP.NET (4.0.30319.0).
This option is not supported on this version of the operating system.  Administrators should instead install/uninstall ASP.NET 4.5 with IIS8 using the "Turn Windows Features On/Off" dialog,  the Server Manager management tool, or the dism.exe command line tool.  For more details please see http://go.microsoft.com/fwlink/?LinkID=216771.
Finished installing ASP.NET (4.0.30319.0).

我检查我的.Net版本,在Turn windows features on/off上分别为3.5和4.8。我选择了4.8,因为如果会导致很多错误。还是我需要选择它?

如果选择.Net 4.8版本,则会出现此错误。

Could not load type 'System.ServiceModel.Activation.HttpModule' from assembly 'System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.

哪个容易解决?还是我都需要解决?

如果有任何解决方案,请告诉我。

提前感谢

asp.net windows iis-10
1个回答
0
投票

解决了我的问题。

  1. 转到打开/关闭窗口功能
  2. 扩展.NET Framework 4.8高级
  3. 服务扩展WCF服务
  4. 检查HTTP激活

刷新网站,它应该可以工作!

© www.soinside.com 2019 - 2024. All rights reserved.