在Windows XP工具集方面需要帮助(visual studio 141 xp,C ++) [英] Need help with windows XP tool set (visual studio 141 xp, C++)

查看:519
本文介绍了在Windows XP工具集方面需要帮助(visual studio 141 xp,C ++)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用VS 2017 RC来构建一个在MS-Dos环境中运行的便携式计算器。它完全在我的笔记本电脑上运行(赢10)。但是,它不能在我的学校计算机实验室上运行(赢得XP)。我将我的项目设置为visual studio 141 xp工具集。但是,它产生
大约420个错误。像缺少库这样的东西,例如< conio.h>或错误语法。有没有办法让我的程序在win XP上运行? 

I am using VS 2017 RC to build a portable calculator that run in MS-Dos environment. it run perfectly on my laptop(win 10). however, It can not run on my school computer lab (win XP). I set my project to visual studio 141 xp toolset. However, It generates about 420 errors. something like missing library such as <conio.h> or error syntax. Is there any way to make my program run on win XP ? 

谢谢

抱歉我的英语不好。

推荐答案

Windows XP的独特平台工具集的原因是Windows 8.x SDK和Windows 10 SDK不支持针对Windows XP / Windows Server 2003.当您使用v141_xp平台工具集时,您的程序使用Windows SDK
7.1A构建,此时此时已为8年。这可能导致在使用Windows 8 SDK或Windows 10 SDK时未显示的错误/警告。

The reason there is a distinct Platform Toolset for Windows XP is that the Windows 8.x SDK and Windows 10 SDKs do not support targeting Windows XP / Windows Server 2003. When you use the v141_xp Platform Toolset, your program is built with the Windows SDK 7.1A which is at this point 8 years old. This can result in errors/warnings that didn't show up when using the Windows 8 SDK or Windows 10 SDK.

对于C ++,您需要将_WIN32_WINNT预处理器定义显式设置为值支持Windows XP:0x0502。

Se
e MSDN

For C++, you need to explicitly set the _WIN32_WINNT preprocessor define to a value that supports Windows XP: 0x0502. See MSDN.

#include <WinSDKVer.h>
#define _WIN32_WINNT 0x0502
#include <SDKDDKVer.h>

其次,请确保您的学校计算机实验室使用的是Windows XP Service Pack 3。 v141_xp平台工具集需要Service Pack 3.

Secondly, make sure your school computer lab is using Windows XP Service Pack 3. The v141_xp Platform Toolset requires Service Pack 3.

您还需要在Windows XP系统上运行VS 2017 REDIST,如果您没有管理员,可能会遇到问题权利。请记住,VS 2017仍然是预览软件

直到3月7日

You'll need to run the VS 2017 REDIST on the Windows XP system as well, which likely will have problems if you don't have administrator rights. Remember that VS 2017 is still preview software until March 7.

参见
VS 2012 Update 1
以获取更多笔记wrt使用v1XX_xp平台工具集时使用DirectX API。

See VS 2012 Update 1 for some more notes w.r.t. to DirectX APIs when using the v1XX_xp Platform Toolset.


这篇关于在Windows XP工具集方面需要帮助(visual studio 141 xp,C ++)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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