To configure asp.net-core project to use "framework" target (net462) it is required to delete package from csproj file:

<PackageReference Include="Microsoft.NETCore.App" Version="1.1.0" />

Because it is for "Core" platform only.

May be because of this Visual Studio F5 button (Run) stopped working:

enter image description here

Is it possible to "reintegrate" asp.core targeted to net462 with Visual Studio?

ToolsVersion problem:

One question aside, what we should know about ToolsVersion from <Project Sdk="Microsoft.NET.Sdk.Web" ToolsVersion="15.0"> ? Till that moment I thought that we should worry about dotnet -v (aka tooling version). How to know which sdk's "ToolsVersion" is the last and which is actually installed on developer's computer?

Reproducing

I can't reproduce it with VS default ASP.CORE projects. It is happens only with Spa Services projects.

1

There are 1 best solutions below

2
On BEST ANSWER

As "The Pax Bisonica" suggested in comments:

Changing:

<OutputType>winexe</OutputType>

To:

<OutputType>Exe</OutputType>

helps, but only after Visual Studio restart (dotnet restore and dotnet build is not enough!!!). Together I have removed /bin and /obj folders so may be those steps also need to be included.

About:

<Project Sdk="Microsoft.NET.Sdk.Web" ToolsVersion="15.0">

As I understand there ToolsVersion shares its value "15" from "Visual Studio 15" - prerelease/development name of Visual Studio 2017. I can't find an information about plans to change it with VS 2017 release. VS 2015's editions ToolsVersion = 14