|
-
May 29th, 2002, 08:56 AM
#1
clear screen in console
Hi,
how can I clean the console screen?
Okay, I can use system("clear"); or system("cls"); but I don't want to use system commands.
Thanks,
Alexander
-
May 29th, 2002, 10:34 AM
#2
Use BIOS/DOS calls .. Some Interrupt.
You will have to code Assembly in C/C++
Cheers
V
-
May 29th, 2002, 10:52 AM
#3
Re: clear screen in console
Originally posted by AlexanderS
Hi,
how can I clean the console screen?
Okay, I can use system("clear"); or system("cls"); but I don't want to use system commands.
Thanks,
Alexander
If your console is 25 lines:
Code:
#include <iostream>
void ClearConsole( )
{
for ( int i =0; i < 25; ++i )
std::cout << std::endl;
}
Other than that, there is no standard way in C++ to clear the console, or do any kind of console related programming. All of this is OS and compiler dependent, so you need to do research on the functions that your compiler supports in doing these things, or check how your OS does these things.
Regards,
Paul McKenzie
-
May 29th, 2002, 01:46 PM
#4
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|