[英]VS 2022 - cannot change Target Platform to .Net 6.0 for a project created in VS 2019
Just installed VS 2022 on a machine, after I removed VS 2019 (VM with limited space).在我删除了 VS 2019(空间有限的虚拟机)之后,刚刚在一台机器上安装了 VS 2022。 VS 2022 installed fine.
VS 2022 安装正常。 I can create a .Net 6.0 project and compile it - no problem.
我可以创建一个 .Net 6.0 项目并编译它 - 没问题。 I can open the project I created in VS 2019 - and compile it - no problem.
我可以打开我在 VS 2019 中创建的项目 - 并编译它 - 没问题。
But - when I try to change the Target Platform from .Net 4.6 to 6.0 - I do not see anything above .Net 4.8 in the drop down list.但是 - 当我尝试将目标平台从 .Net 4.6 更改为 6.0 时 - 我在下拉列表中没有看到高于 .Net 4.8 的任何内容。
This is VS 2022 - and I CAN create a new .Net 6.0 project and compile it.这是 VS 2022 - 我可以创建一个新的 .Net 6.0 项目并编译它。
And when I go into that New Project's Properties - I can see .Net 6.0 in the dropdown...当我进入那个新项目的属性时 - 我可以在下拉菜单中看到 .Net 6.0 ......
So - I think I am missing a step to get my older 2019 project - fully upgraded to 2022. I loaded the project in 2022 - but when I look at the properties for that project, the screen looks like it did in 2019 --- but for a new project the properties screen looks VERY different (as you can see in the two screen shots attached).所以 - 我想我错过了让 2019 年旧项目的一步 - 完全升级到 2022 年。我在 2022 年加载了该项目 - 但是当我查看该项目的属性时,屏幕看起来就像 2019 年一样 ---但是对于一个新项目,属性屏幕看起来非常不同(正如您在所附的两个屏幕截图中看到的那样)。
Does anyone have any thoughts as to what steps I might be missing?有没有人对我可能缺少哪些步骤有任何想法? I loaded .Net 6.0 SDK on this machine (hence why I can create a .net 6.0 project and compile it :)
我在这台机器上加载了 .Net 6.0 SDK(因此我可以创建一个 .net 6.0 项目并编译它:)
Are there other steps to making an older project work like it was created in VS 2022 - and then make it use .Net 6.0 ???是否还有其他步骤可以使旧项目像在 VS 2022 中创建的那样工作 - 然后使用 .Net 6.0 ???
Any thoughts would be much appreciated!!任何想法将不胜感激!
There is no direct upgrade from .NE Framework (any version) (but there is a tool for some types of projects) to anything .NET Core.没有从 .NE Framework(任何版本)(但有适用于某些类型项目的工具)直接升级到任何 .NET Core。 And .NET 5 & 6 are based on Core.
.NET 5 & 6 基于 Core。
Aiitionally, VS2019 does not support .NET 6 (as of .NET 6 RTM). Aiitionally,VS2019 不支持 .NET 6(从 .NET 6 RTM 开始)。 You need VS2022 for that.
为此,您需要 VS2022。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.