无法在 Visual Studio 2017 RC 中启动 IIS Express

Unable to launch IIS Express in Visual Studio 2017 RC

有一个 Web 应用程序在 Visual Studio 2015 Update 3 中完美运行。我将项目移植到Visual Studio 2017 RC 并编译成功。调试应用程序时,IIS Express 在 VS 2017 RC 的输出窗格中转储以下消息后终止:

The program '[7896] iisexpress.exe: Program Trace' has exited with code 0 (0x0).
The program '[8488] dotnet.exe' has exited with code 0 (0x0).
The program '[8488] dotnet.exe: Program Trace' has exited with code 0 (0x0).
The program '[7896] iisexpress.exe' has exited with code 0 (0x0).

使项目 运行 和可调试的解决方案是什么?

您的 launchSettings.json 文件中很可能缺少 "commandName": "Project"。 我已经描述了我在移植到 VS 2017 时遇到的问题 here

在我使用 Visual Studio 2017 社区版的情况下,我尝试了以下操作:

  • 删除 Documents 中的 IISExpress 配置文件夹
  • 删除项目根目录下隐藏的.vs
  • 重启Visual Studio2017和电脑

在我重新 运行 Visualt Studio 安装程序并选择选项 "Repair" 之前,没有任何效果。然后一切都开始工作了。