I am creating a .NET Core application. Why is there an option to "Run on .NET Framework" (see picture below)? Doesn't .NET Core already include .NET framework in a sense?
Also as .NET Core is cross-platform, why I need .NET framework which only supports Windows?

- 194
- 1
- 1
- 15
-
I made an edit to your question, but it was unclear what you were asking. – Connor Low Mar 11 '21 at 20:17
-
It is not a "new" option, but rather old (since .NET Core 1.x). https://github.com/aspnet/Announcements/issues/324 Anyway you won't get that for ASP.NET Core 3.x and above. – Lex Li Mar 12 '21 at 00:57
1 Answers
If the "Run on .NET Framework" checkbox is selected, the generated project will create an ASP.NET Core 2.1 application that runs on .NET Framework rather than .NET Core.
It is worth mentioning that ASP.NET Core 2.1 is the last version that supports .NET Framework. Look at the .NET Core and .NET 5 Support Policy for details.
.NET Core does not include .NET Framework, they are different runtimes and frameworks but have a lot in common
In 2002, Microsoft released .NET Framework, a development platform for creating Windows apps. Today .NET Framework is at version 4.8 and is still supported by Microsoft.
In 2014, Microsoft began writing a cross-platform, open-source successor to .NET Framework. This new implementation of .NET was named .NET Core until it reached version 3.1. The next version after .NET Core 3.1 is .NET 5.0. Version number 4 was skipped to avoid confusion between this implementation of .NET and .NET Framework 4.8. The name "Core" was dropped to make clear that this is now the main implementation of .NET.
Source: https://learn.microsoft.com/en-us/dotnet/core/introduction#net-core-and-net-5

- 2,321
- 1
- 15
- 26
-
That means the .NET Core application will not be a cross platform app if it is selected? It's ability will be limited, right? – username_allowed Mar 12 '21 at 00:53
-
1Yes, if selected, the application will be .NET Framework application and limited to Windows. The target framework drop down box is misleading. If you are not tied to .NET Framework for a good reason, .NET Core is the way to go. – Christian Held Mar 12 '21 at 08:30