Visual C ++ .Net:找不到'stdlib.h'? [英] Visual C++.Net: Cannot find 'stdlib.h'?

查看:114
本文介绍了Visual C ++ .Net:找不到'stdlib.h'?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




我最近安装了Visual Studio .Net 2003,我正在尝试编译

并运行一个简单的Windows窗体应用程序(使用VS向导)。当试图运行我

得到一条错误消息告诉我:致命错误C1083:无法打开包含

文件:''stdlib.h'':没有这样的文件或目录。我浏览过C:\Program

Files \ Microsoft Visual Studio .NET 2003 \Vc7 \ include并找到了文件

那里。


有什么不对?我也尝试卸载并重新安装。


祝你好运

P?¥l Eilertsen

解决方案



" P?l Eilertsen" < PL ********* @ discussions.microsoft.com>在消息中写道

新闻:C0 ********************************** @ microsof t.com ...



我最近安装了Visual Studio .Net 2003,我正在尝试编译
并运行一个简单的Windows窗体应用程序(使用VS向导)。当试图运行
时,我收到一条错误消息告诉我:致命错误C1083:无法打开包含
文件:''stdlib.h'':没有这样的文件或目录。我浏览过C:\Program
Files \ Microsoft Visual Studio .NET 2003 \Vc7 \ include并在那里找到
文件。

什么可以错误?我也尝试卸载并重新安装。

最好的问候
P?l Eilertsen




Visual Studio .NET 2003(C ++ )不再支持许多旧的.h标题

(Visual Studio .NET 2002),而是支持新标题。标准标题

,如cstdlib。试试#include< cstdlib>在你的代码中代替#include

< stdlib.h> ;.

希望这会有所帮助。


-

彼得[MVP视觉开发者]

所有行业的杰克,无人掌握。


Peter van der Goes写道:

Visual Studio .NET 2003(C ++)不再支持许多旧的.h标题
(Visual Studio .NET 2002),而是支持new ;标准标题
如cstdlib。试试#include< cstdlib>在你的代码中代替#include
< stdlib.h>。
希望这会有所帮助。



实际上,stdlib.h(和所有C90子集头)文件)是C ++ 98的一部分,

和stdlib.h用VC ++ 2003编译。


-

Ioannis Vranos


我实际上现在已经能够编译但是我必须手动将

路径包含到项目属性下的文件中,并且还包含其他包含和lib

路径。所以对于这个项目,我现在可以编译。但是每次我都不得不这样做,而且我不想这样做。它必须是一些全局变量

,我可以改变吗?我在使用需要

编译器的第三方应用程序时也遇到了问题。我是试图使用CMake并得到一个错误,无法找到kernel32.lib

。我认为这是由于同样的错误,并且在这里

没有额外包含路径调整。所以我被卡住了。


必须有人知道答案!!


P?¥l


" Ioannis Vranos"写道:

Peter van der Goes写道:

Visual Studio .NET 2003(C ++)不再支持许多旧的.h标题
(Visual Studio .NET 2002),而不是支持新。标准标题
如cstdlib。试试#include< cstdlib>在你的代码中代替#include
< stdlib.h>。
希望这会有所帮助。



实际上,stdlib.h(和所有C90子集头)文件)是C ++ 98的一部分,
和stdlib.h用VC ++ 2003编译。

-
Ioannis Vranos



Hi,

I have recently installed Visual Studio .Net 2003 and am trying to compile
and run a simple windows form app (used the VS wizard). When trying to run I
get an error message telling me: "fatal error C1083: Cannot open include
file: ''stdlib.h'': No such file or directory". I have browsed to C:\Program
Files\Microsoft Visual Studio .NET 2003\Vc7\include and have found the file
there.

What can be wrong? I have also tried to uninstall and reinstall.

Best regards
P?¥l Eilertsen

解决方案


"P?l Eilertsen" <Pl*********@discussions.microsoft.com> wrote in message
news:C0**********************************@microsof t.com...

Hi,

I have recently installed Visual Studio .Net 2003 and am trying to compile
and run a simple windows form app (used the VS wizard). When trying to run I get an error message telling me: "fatal error C1083: Cannot open include
file: ''stdlib.h'': No such file or directory". I have browsed to C:\Program
Files\Microsoft Visual Studio .NET 2003\Vc7\include and have found the file there.

What can be wrong? I have also tried to uninstall and reinstall.

Best regards
P?l Eilertsen



Visual Studio .NET 2003 (C++) no longer supports many of the old .h headers
(Visual Studio .NET 2002 did), instead supporting the "new" standard headers
such as cstdlib. Try #include <cstdlib> in your code in place of #include
<stdlib.h>.
Hope this helps.

--
Peter [MVP Visual Developer]
Jack of all trades, master of none.


Peter van der Goes wrote:

Visual Studio .NET 2003 (C++) no longer supports many of the old .h headers
(Visual Studio .NET 2002 did), instead supporting the "new" standard headers
such as cstdlib. Try #include <cstdlib> in your code in place of #include
<stdlib.h>.
Hope this helps.


Actually, stdlib.h (and all C90 subset header files) are part of C++98,
and stdlib.h compiles with VC++ 2003.

--
Ioannis Vranos


I have actually been able to compile now but I had to manually include the
paths to the files under project properties and additional include and lib
paths. So for this project I now can compile. But I am left with having to do
this every time and I don''t want to do that. It must be some global variables
that I can change? I also have problems using third party apps that need the
compiler. I am i.e. trying to use CMake and get an error that kernel32.lib
cannot be found. I quess that this is due to the same error, and here there
are no "additional include path" to adjust. So I am stuck.

There must be someone that knows the answer to this!!

P?¥l

"Ioannis Vranos" wrote:

Peter van der Goes wrote:

Visual Studio .NET 2003 (C++) no longer supports many of the old .h headers
(Visual Studio .NET 2002 did), instead supporting the "new" standard headers
such as cstdlib. Try #include <cstdlib> in your code in place of #include
<stdlib.h>.
Hope this helps.


Actually, stdlib.h (and all C90 subset header files) are part of C++98,
and stdlib.h compiles with VC++ 2003.

--
Ioannis Vranos



这篇关于Visual C ++ .Net:找不到'stdlib.h'?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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