Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

.NET 5 not available in Visual Studio 2019

I have downloaded and installed .NET Core 5.0 SDK (v5.0.100-preview.1) in my Visual Studio 2019. But it is not available in Target framework. Am I missing something?

like image 488
Hamid Noahdi Avatar asked Mar 25 '20 04:03

Hamid Noahdi


People also ask

Is .NET 5 included in Visual Studio?

Starting with the June 2022 servicing update for Visual Studio 2019 16.11 and Visual Studio 2019 16.9, the . NET 5.0 component in Visual Studio will be changed to out of support and optional. This means that workloads in Visual Studio may be installed without installing . NET 5.0.

How do I get .NET 5 in Visual Studio?

Go to Tools > Options... , and under Preview Features , tick the Use previous of . NET Core SDK (required restart) checkbox as shown in the following: Now just restart/close Visual Studio 2019 and you should now be able to see ASP.NET Core 5.0 in the list when creating a new project from the default templates.

What version of Visual Studio do I need for .NET 5?

You must have version 16.8.0 in order to have .Net Core 5.0 Net Core 5.0 in Visual Studio version 16.8.


2 Answers

You need to install the latest preview of Visual Studio 2019 16.8, refer to

https://devblogs.microsoft.com/aspnet/asp-net-core-updates-in-net-5-preview-1/

You also need to explicitly enable preview versions within Visual Studio itself:

enable previews

Then you should see it:

enter image description here

like image 77
Ryan Avatar answered Nov 13 '22 15:11

Ryan


Specs: VS Version 16.8.0

Target Version of .Net Core: 5.0

You must have version 16.8.0 in order to have .Net Core 5.0

If you still have problems with Visual Studio not showing .Net Core 5.0 in Visual Studio version 16.8.0 (and assuming you downloaded the .NET Core 5.0 SDK for Visual Studio), well, apparently (and correct me if I'm wrong) it is now called just .Net 5.0, omitting the Core.

enter image description here

After selecting .NET 5.0, I was able to install other libraries which are currently version 5.0+ and dependent on .NET Core 5.0+

Is the new name intentional? Anyways, here some evidence of this working (I was able to install the newest version of Newtonsoft and Entity Framework for .Net Core):

enter image description here

Funny enough, when I try to create a new .Net Core project, the version shows up as expected:

enter image description here

like image 34
LuisDev99 Avatar answered Nov 13 '22 16:11

LuisDev99