Archived

This topic is now archived and is closed to further replies.

Starwind8748

I need a Clear Screen Function for C++

Recommended Posts

system("cls")
I think you need stdlib.h

If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization.

Share this post


Link to post
Share on other sites
for console applications i think this will be machine dependant.

however, under Win32 i believe: system("cls");.

To the vast majority of mankind, nothing is more agreeable than to escape the need for mental exertion... To most people, nothing is more troublesome than the effort of thinking.

Share this post


Link to post
Share on other sites
Theres always a better way to do it other than system (I don''t know why, but thats what I always hear experianced people say, and I trust them more than my biased ''commen sense'')
I think theres a function in conio.h called clrscr(), I''m not sure though...it might be stdio.h...

"I''ve learned something today: It doesn''t matter if you''re white, or if you''re black...the only color that REALLY matters is green"
-Peter Griffin

Share this post


Link to post
Share on other sites
Any DOS command will work in that if you are under windows. Under linux, any shell command will work. Howver, as far as I can remember, system commands don''t work with WinSIOUX ... so if you are having a problem related to that, that is probably the reason.

"If patience is a virtue, and ignorance is bliss, you can have a pretty good life if you''re stupid and willing to wait"

Share this post


Link to post
Share on other sites