English 中文(简体)
clrscr()没有在VC++(VS 2008)工作。
原标题:clrscr()not working in VC++(VS 2008).....?
  • 时间:2010-09-05 12:26:22
  •  标签:
  • visual-c++

2008年,我在VC++设立了一个空置项目,并增加了一个来源文件,作为......。

......

 #include<stdio.h>    

 #include<conio.h>

int main()
{
  ....
  clrscr();
  .....
  return 0;
}

......

www.un.org/Depts/DGACM/index_spanish.htm 我收到这些错误/警告:。

警告1:C4013:cl子没有定义;在c:c oh.c 170 至H

错误3:LNK2019:未解决的外部编号——在职能中被引用的包括:main toH.obj 还是

问题是什么?

提前感谢。

最佳回答

利用FillConsoleOutputCharacter和FillConsoleOutputAttribute的职能。 甚至有一个实例说明如何在MSDN中做到这一点,方便地称为“

问题回答

Are you trying to mix Borland libraries with VC++? That could be the problem. Can you clear the console instead by sending a bunch of s?

问题在于,从C++到C.R.C.R.C.C.R.C.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.C.R.R.R.M.R.M.M.R.R.M.M.M.R.M.M.M.C.R.R.R.M.M.M.M.M.M.R.R.R.M.M.M.M.M.M.M.M.M.M.M.R.M.M.M.M.M.M.M.M.R.M.M.M.M.M.M.M.M.M.M.,P.M.R.M.R.R.M.M.M.M.M.M.R.M.M.M.M.M.M.M.R

或者,你可以使用系统(“组件”),而不是cl子。 这不是最佳解决办法,但就我而言,我只是测试一个老方案,试图解决这一问题,使我感到愤怒! lo

#define clrscr(); system("cls");

它将保留你的代码,并自动改变所有集装箱。 如果你想要的话,你可以做。

或许,如果出现错误,你还需要包括分层平衡。

#include <stdlib.h>

避免使用cl(cl); 使用系统(“cl”);





相关问题
how to reliable capture display setting changed

static void Main() { // Set the SystemEvents class to receive event notification when a user // when display settings change. SystemEvents.DisplaySettingsChanged += new ...

Why use CComBSTR instead of just passing a WCHAR*?

I m new to COM. What exactly is the advantage of replacing: L"String" with CComBSTR(L"String") I can see a changelist in the COM part of my .NET application where all strings are replaced in this ...

COM Basic links

folks can you provide me the tutorial link or .pdf for learning basic COM?. i do google it.. still i recommend answers of stackoverflow so please pass me.. Thanks

Statically linking Winsock?

I m using Winsock 1.1 in my project. I include wsock32.lib in "Additional Dependencies". I m looking at the DLL project using depends.exe and notice that the DLL depends on wsock32.dll. How can I ...

热门标签