将visual studio vc++2003项目转换为visual studio vc++2010[英] converting visual studio vc++ 2003 project to visual studio vc++2010

本文是小编为大家收集整理的关于将visual studio vc++2003项目转换为visual studio vc++2010的处理/解决方法,可以参考本文帮助大家快速定位并解决问题,中文翻译不准确的可切换到English标签页查看源文。

问题描述

大家好,
随着微软提供新版本的 studio.i,我决定将基于窗口的应用程序从 Visual Studio 2003 移至 Visual Studio 2010.

从 2010 年到 2003 年,一个伟大的技术方面更多地使用完全控制.

好的,
但是在将我的基于窗口的程序从 2003 年转换到 2010 年时出现了一个问题,
2010 版的工作室给出了以下 2003 年未给出的错误.

for(int i = 0;i<10;i++){……}

未声明的标识符"i"

现在,当我尝试时,同样的问题解决了,
int i;for(i = 0;i;<10;i++){……}


如果我采用上述技术,它往往会取代我的所有 for 循环.
这可能需要我 7 或 8 天.
所以有两种选择.
谷歌

专家.

在谷歌上花了我一整天后,没有发现任何有用的想法.
所以需要专家.

请,
甚至为我提供一个提示,将我的整个 Visual Studio 2003 项目转换为 2010,而不会出现任何错误.


谢谢.
santosh dhanawade.

推荐答案

您可以更改您的项目设置.请参阅 /Zc:forScope(强制循环范围内的一致性)[^].

也可以使用
conform pragma[^].

本文地址:https://www.itbaoku.cn/post/1356154.html

问题描述

Hi all,
As microsoft provide new version of studio.i deciced to moved my window based application from visual studio 2003 to visual studio 2010.

a great Techanology aspected more use full control from 2010 compare to 2003.

Fine,
but one problem arise when convert my window based program from 2003 to 2010,
2010 version of studio gives following errors that not given in 2003.

for(int i = 0;i<10;i++)
{
    ......
}

Undeclared identifier "i"

now same problem solved when im try like,
int i;
for(i = 0;i;<10;i++)
{
    ......
}


if i go with above techanique that tends to replace my all for loops.
that may take my 7 or 8 days.
So there are two aternative.
GOOGLE
and
Experts.

After spending my whole day on google doen''t found any think useful.
So need expert.

Please ,
Provide me even single hint that convert my whole visual studio 2003 project to 2010 without an single error.


Thanks.
santosh dhanawade.

推荐答案

You may change your project settings. See /Zc:forScope (Force Conformance in for Loop Scope)[^].

The option can be also changed in the source files using the conform pragma[^].