从 dnx 升级到 vs2017 aspnetcore [英] Upgrading from dnx to vs2017 aspnetcore

查看:32
本文介绍了从 dnx 升级到 vs2017 aspnetcore的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以我刚刚安装了 VS2017 并加载了我的应用程序.它要求迁移,并且我现在已经解决了很多问题.最后剩下的问题如下:

So I just installed VS2017 and loaded my application. It asked to migrate and there were a tonne of issues which I have now fixed. The last remaining issues are the following:

我希望第一个能解决第二个.当我尝试调试我的应用程序时,它指出:

The first one I hope will solve the second. When I try to debug my application it states that:

项目不知道如何运行配置文件iis express

the project doesnt know how to run the profile iis express

当我转到项目属性时,我可以在 调试 选项卡中看到,有一个 IISEXPRESS 配置文件启动 iisexpress.下拉列表中的另外两个选项是项目可执行.我想知道 IISExpress 的来源.这显然需要修改,但它不像其他两个选项(可以在 IDE 中更改).

When I go to the project properties, I can see in the Debug tab, there is a IISEXPRESS profile which launches iisexpress. The other two options in the dropdown are Project and Executable. I would like to know where the IISExpress is pulled from. That obviously needs modifying but it's not like the other two options (which can be changed in the IDE).

有人知道怎么改吗?

更新

看起来设置保存在 launchSettings.json 文件中.我添加了这个:

It looks like the settings are saved in the launchSettings.json file. I added this:

"profiles": {
    "IIS Express": {
        "commandName": "IISExpress",
        "launchBrowser": true,
        "environmentVariables": {
            "ASPNETCORE_ENVIRONMENT": "Development"
        }
    }
}

但仍然出现相同的错误.

but still get the same error.

推荐答案

这个错误发生在我身上,我使用的是 Visual Studio 2019:

This error occurred to me, I use Visual Studio 2019:

该项目不知道如何运行配置文件 IIS Express.

The project doesn't know how to run the profile IIS Express.

解决方案:我将 Visual Studio 2019 更新到最新版本

Solution: I updated Visual Studio 2019 to the latest version

工具 ->获取工具和功能

Tools -> Get tools and features

一切又正常了!

已安装的版本:微软 Visual Studio 社区 2019Versão 16.6.5

Installed version: Microsoft Visual Studio Community 2019 Versão 16.6.5

这篇关于从 dnx 升级到 vs2017 aspnetcore的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆