locked
The current .NET SDK does not support targeting .NET Standard 2.0. Either target .NET Standard 1.6 or lower, or use a version of the .NET SDK that supports .NET Standard 2.0. RRS feed

  • Question

  • Hello,

    I have downloaded and opened a solution from GitHub (this one in case anyone wants to try it themselves), but get errors of the form...

    The current .NET SDK does not support targeting .NET Standard 2.0.  Either target .NET Standard 1.6 or lower, or use a version of the .NET SDK that supports .NET Standard 2.0.

    The current .NET SDK does not support targeting .NET Core 2.0.  Either target .NET Core 1.1 or lower, or use a version of the .NET SDK that supports .NET Core 2.0.

    I have installed the full .NET Core 2.2 SDK - Windows x64 Installer (v2.2.104), and have restarted my machine, but still get the same errors.

    If I open a command prompt and type dotnet --info, I see that version 2.2.104 is installed.

    I'm using VS Enterprise 2017 on Windows 7 Pro x-64.

    Thanks



    • Edited by Mr Yossu Wednesday, February 13, 2019 5:57 PM
    Wednesday, February 13, 2019 4:31 PM

Answers

  • I was just about to reply and ask why I should need to download v2.0 when I have 2.2 installed. Before doing that, I opened the solution again, and it now builds fine!

    I have no idea why it didn't before, as I had even restarted my machine between installing the SDK and rebuilding, but it seems that the second restart was needed.

    Thanks anyway.

    • Marked as answer by Mr Yossu Sunday, February 17, 2019 4:51 PM
    Sunday, February 17, 2019 4:51 PM

All replies

  • Hi,

    Welcome to MSDN forum.

    According to the error message, the project require .net core 2.0. .NET Core 2.0 is supported starting with .NET Core SDK 2.0.0. I suggest going to https://dotnet.microsoft.com/download/archives to obtain the latest2.1.202 SDK, which should enable supporting .NET Core 2.0. After this, Go to Project -> projectname Properties... and change the Target framework.

    Best regards,

    Joyce



    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Thursday, February 14, 2019 9:45 AM
  • I was just about to reply and ask why I should need to download v2.0 when I have 2.2 installed. Before doing that, I opened the solution again, and it now builds fine!

    I have no idea why it didn't before, as I had even restarted my machine between installing the SDK and rebuilding, but it seems that the second restart was needed.

    Thanks anyway.

    • Marked as answer by Mr Yossu Sunday, February 17, 2019 4:51 PM
    Sunday, February 17, 2019 4:51 PM