Project referencing .net4.6 in a .net4.8 installed machine

Vivek M 21 Reputation points

I was targeting my project to .net4.6, which had a framework level deadlock issue. The issue in fixed (ServicePoint.ConnectionLimit) in .net4.8.

I have installed .net4.8 in the target machine (with ARM templates), which basically replaces .net4.6 in C:\Windows\Microsoft.NET\Framework.

So even if I target my project to .net4.6 it will be using the new dll (which has the fix)

If my above understanding is correct should I change my target framework of the project or shall I stay in 4.6 and continue running in .net4.8 installed machine (to make use of the fix)?

An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,637 questions
.NET Runtime
.NET Runtime
.NET: Microsoft Technologies based on the .NET software framework.Runtime: An environment required to run apps that aren't compiled to machine language.
1,136 questions
0 comments No comments
{count} votes

Accepted answer
  1. Jiachen Li-MSFT 27,916 Reputation points Microsoft Vendor

    Hi @Vivek M ,
    Yes, your understanding is correct, upgrading project targets to the .NET Framework 4.8 is not necessary.
    However, upgrading the project target to the .NET Framework 4.8 ensures that users do not run in a .Net Framework 4.6 environment and cause errors.

    .NET Framework 4.x versions are in-place updates to earlier versions. That means the following:

    • You can only have one version of the .NET Framework 4.x installed on your machine.
    • You cannot install an earlier version of the .NET Framework on your machine if a later version is already installed.
    • (4.x) versions of the .NET Framework can be used to run applications built for the .NET Framework 4.0 through that version. For example, .NET Framework 4.7 can be used to run applications built for the .NET Framework 4.0 through 4.7. The latest version (the .NET Framework 4.8) can be used to run applications built with all versions of the .NET Framework starting with 4.0.

    Best Regards.
    Jiachen Li


    If the answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

0 additional answers

Sort by: Most helpful