Visual Studio 2013 社区奇怪的错误 [英] Visual Studio 2013 Community weird errors

查看:36
本文介绍了Visual Studio 2013 社区奇怪的错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近安装了带有更新 4 的 Visual Studio Community 2013,当我尝试构建我的项目时出现这些错误(见下文):

I have recently installed Visual Studio Community 2013 with update 4 and when I try to build my project I get these errors(see below):

C:\Program Files(x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppBuild.targets(362,5): warning MSB8003: Could not find WindowsSDKDir variable from the registry.  TargetFrameworkVersion or PlatformToolset may be set to an invalid version number.
1>  main.cpp
1>c:\program files (x86)\microsoft sdks\windows\v7.1a\include\sal_supp.h(57): warning C4005: '__useHeader' : macro redefinition
1>          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\sal.h(2886) : see previous definition of '__useHeader'
1>c:\program files (x86)\microsoft sdks\windows\v7.1a\include\specstrings_supp.h(77): warning C4005: '__on_failure' : macro redefinition
1>          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\sal.h(2896) : see previous definition of '__on_failure'

如何解决?我尝试了很多方法,但没有成功.

How to solve them? I tried many ways but no luck.

推荐答案

转到控制面板并转到卸载程序.

Go to control panel and go to uninstall program.

选择您的 Visual Studio 社区版本更新 4. 选择更改或修复(如果有).如果它打开到 Visual Studio 窗口,则在那里选择修复.

Choose your visual studio community edition update 4. Select change or repair, if it's there. If it opens to the Visual Studio window then select repair there.

选择修复.

在执行此操作时保持互联网连接,以便更新您的 SDK 和平台工具.

Keep your internet connection on while you do this, so your sdk and platform tools can be updated.

如果这不起作用,有一些更改注册表的链接:

If this doesn't work, there are some links to altering the registry:

https://stackoverflow.com/a/24478856/3956566

https://social.msdn.microsoft.com/Forums/vstudio/en-US/48a4500c-2c48-43dd-822b-10e83258d18b/warning-msb8003-could-not-find-windowssdkdir-variable-from-the-registry-targetframeworkversion-or?forum=visualstudiogeneral

如何将 Msbuild 中的 SGEN 工具路径设置为目标 3.5 框架

https://code.google.com/p/gyp/issues/detail?id=457

这篇关于Visual Studio 2013 社区奇怪的错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆