Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/.net/25.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
.net IIS 10-找不到文件或目录_.net_Iis_Server_Http Status Code 404 - Fatal编程技术网

.net IIS 10-找不到文件或目录

.net IIS 10-找不到文件或目录,.net,iis,server,http-status-code-404,.net,Iis,Server,Http Status Code 404,我有一个在Visual Studio中制作的web应用程序。 每当我导航到它,我就会得到一个404。 例如,我可以访问“xyz.net/res/image.png”,但不能访问“default.aspx” 默认文档: 绑定: 应用程序池: 当我在端口80上导航到localhost时会发生这种情况: 我以前用IIS安装并运行过一个web服务器,但从那以后我重新安装了Windows,我无法理解它。 在修改它之前,我可以访问localhost。 文件路径看起来是正确的,尽管我不认为我能够访问p

我有一个在Visual Studio中制作的web应用程序。 每当我导航到它,我就会得到一个404。 例如,我可以访问“xyz.net/res/image.png”,但不能访问“default.aspx”

默认文档:

绑定:

应用程序池:

当我在端口80上导航到localhost时会发生这种情况:

我以前用IIS安装并运行过一个web服务器,但从那以后我重新安装了Windows,我无法理解它。 在修改它之前,我可以访问localhost。 文件路径看起来是正确的,尽管我不认为我能够访问png文件。
非常感谢您的帮助。

我设法修复了它!我启用了一些Windows功能,仅此而已。
我不知道哪一个有帮助,因为我启用了几十个,但是如果你面对这个问题并且无法解决它,你可以试一试。

其他任何与这个问题斗争的人。修复方法是在Windows控制面板下的“打开/关闭Windows功能”下启用应用程序开发

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.

我附上了在Web服务器IIS>应用程序开发下查找ASP.NET功能的屏幕截图

希望这能帮助任何收到404错误消息的人尝试执行.aspx页面