I have recently converted over from Turbo to Visual and can not figure out the clear screen. I have no references for Visual and the techs have not loaded help files. My students need for their programs.
heyyy...
i thought that system("CLS" took a header file...
#include<stdlib.h>
may just be my compiler that deems it necessary, but hey, thought that i'd jump in
~Thani
I had this same original question. How do you clear the screen? I tried the above suggestions. "cls" produces an "undeclared identifier" error. I tried it with and without the suggested header file; in lower-case and upper-case letters; and with and without empty parentheses. Also, "cls" is not in the help index. What's the explanation here?
the library #include<conio.h> has the function clrscr() which is supposed to clear the screen.
also helpful, in the same library, is the clreol() function, which clears the line, starting at the current cursor position.
i don't have acess to the <conio.h> library, and when my compiler deems me worthy, these commands don't work, but for you it may. it may also be a lvp file; seek, my friend and you shall find!
good luck!
~ThaniCC
<conio.h> is not a library. It is a header file...
The library this header contains definitions for is extremely dependent to the compiler you use.
But since this is VC++ forum, that library is called LIBC.LIB and it is statically linked automatically to each and every program one write in MSVC. It is part of the C Run-time libraries that contain all the C goodies one should never write on his own (like memory allocation functions, string manipulations anso.) unless he's crazy for ASM.
Cheers...
[red]Nosferatu[/red]
We are what we eat...
There's no such thing as free meal... once stated: methane@personal.ro
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.