What version of the .NET platform will be used if there is a lot of it?

If I have several versions of the .NET Framework installed on the machine, will the latest version be used?

Will a .NET application use a specific version of the framework depending on how it was programmed?

+4
source share
3 answers

.NET applications, through their CLR header, determine which version of the runtime they require to run. The ability to create and run various versions of .NET is supported in Visual Studio using the multi-targeting function.

+5
source

This is a property of every project (csproj).
You can change it on the "Application" tab in the "Target Structure" section

+1
source

Everything regarding the application that he himself, the developer chooses which suitable Framework that he / she wants to program against

enter image description here

Then, when creating an installation project for deploying the application, there is a flag that informs you of the installation of this version of the Framework, if clients do not already have it

enter image description here

This is valid for any .NET application.

We developers tend to think:

Do I need new features of the latest system?

because it will install a new package in the client, and sometimes we really don’t need, and if everyone has Vista / Windows 7, .NET 3.5 already exists, so we go for 3.5

+1
source

Source: https://habr.com/ru/post/1338055/


All Articles