Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VS 2015 Toolset may be unknown or missing

I try to publish project to my file directory.

I take a this message. But do not shown any error. Error list is empyty.

2> Building with tools version "14.0".

2> Project file contains ToolsVersion="12.0". This toolset may be unknown or missing, in which case you may be able to resolve this by installing the appropriate version of MSBuild, or the build may have been forced to a particular ToolsVersion for policy reasons. Treating the project as if it had ToolsVersion="14.0". For more information, please see http://go.microsoft.com/fwlink/?LinkId=293424. 2> Target "ValidateMSBuildToolsVersion" skipped. Previously built unsuccessfully. 2>Done building project "project_name.csproj" – FAILED. 2> ========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ========== ========== Publish: 0 succeeded, 1 failed, 0 skipped ==========

like image 236
TesterG Avatar asked Jan 17 '18 08:01

TesterG


1 Answers

VS 2015 Toolset may be unknown or missing

According to the error message "Project file contains ToolsVersion="12.0". ", it shows that your project was upgraded from Visual Studio 2013. So when you publish it with Visual Studio 2015, you may get this error "This toolset may be unknown or missing..."

To resolve this issue, you can try to update your project file: Right your project->Unload project->Edit Yourprojectname.csproj->change the ToolsVersion="12.0" to ToolsVersion="14.0" in the second line.

<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

If you are using MSBuild command line build your project, you can can override the ToolsVersion Settings of Projects and Solutions by using command prompt:

msbuild.exe someproj.proj /tv:14.0
like image 157
Leo Liu-MSFT Avatar answered Oct 24 '22 17:10

Leo Liu-MSFT