Project file contains ToolsVersion="12.0". This toolset may be unknown or miss

用VS2010打開解決方案時,輸出窗口有如下提示信息:

1>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="4.0". For more information, please see http://go.microsoft.com/fwlink/?LinkId=291333.


發生此警告的原因:

原本是VS2010的項目用VS2013打開後,然後又強行轉爲VS2010項目。


解決方案如下:

用文本編輯器(例如Notepad++)打開VC項目(後綴名爲.vcxproj),找到這一行內容:

<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

把 ToolsVersion="12.0"  改爲  ToolsVersion="4.0" 即可。

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章