运行 C++ 时出现问题使用DOS框的程序?
在 Windows XP 中运行的相同程序不能在使用 DOS 框的 Windows 7 中运行。 我在打开 stdio.h conio.h 时出错?我怎样才能克服这个问题?
The same program which is running in Windows XP is not running in Windows 7 using DOS box.
I get an error in opening stdio.h conio.h? How can I overcome this problem?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
运行和编译程序是有区别的。你问题上的标签暗示你的意思是在你写“运行”时进行编译。阅读您的问题并进行更改:问题是您没有在第二台机器上正确安装编译器,以便它可以找到其头文件,例如
。它实际上与您使用的 Windows NT 版本几乎无关,而与使用正确的目录、环境变量等正确安装编译器有关。There's a difference between running and compiling a program. The tags on your question imply that you mean compiling when you write "running". Reading your question with that alteration: The problem is that you've not installed your compiler correctly on the second machine, so that it can locate its header files such as
<stdio.h>
. It really has almost nothing to do with the version of Windows NT that you are using, and everything to do with installing the compiler correctly with the right directories, environment variables, and whatnot.我认为您使用的是旧的 TC 编译器。我建议你切换到新的编译器 gcc。您可以使用 mingw 下载 Codeblock IDE。
如果你不关心第一点。然后确保 TC 中包含正确的包含路径。转到选项并检查包含目录..
I think you are using old TC compiler . I will suggest you to switch to new compiler gcc. You can download Codeblock IDE with mingw.
If you don't care about the first point. Than make sure you have correct include path in TC . go to options and check include directory..