How do I clear the text from my screen, other than a bunch of \n's or
endl's?
Tim M. 18 59619
"Tim Mierzejewski" <ti******@yahoo .com> wrote... How do I clear the text from my screen, other than a bunch of \n's or endl's?
Please read FAQ 15.20. You can find FAQ
here: http://www.parashift.com/c++-faq-lite/
Victor
Tim Mierzejewski wrote: How do I clear the text from my screen, other than a bunch of \n's or endl's?
C++ can not clear the screen, as indicated in the FAQ Victor pointed you to.
However, you can ask the OS to do it for you. The most common ways to do
this are 'system("cls"); ' in Windows and system("clear") ;' in Linux. The
system function is defined in <process.h>
--
Unforgiven
"Not only do I not know the answer
I don't even know what the question is"
My world - Metallica
"Unforgiven " <ja*******@hotm ail.com> wrote in message
news:bd******** ****@ID-136341.news.dfn cis.de... Tim Mierzejewski wrote: How do I clear the text from my screen, other than a bunch of \n's or endl's? C++ can not clear the screen, as indicated in the FAQ Victor pointed you
to.
Huh? C++ can do a lot of things using the OS specific libraries. Dont say
C++ cannot clear the screen. Instead, you should say standard C++ cannot
clear the screen.
However, you can ask the OS to do it for you. The most common ways to do this are 'system("cls"); ' in Windows and system("clear") ;' in Linux. The system function is defined in <process.h>
-- Unforgiven
"Not only do I not know the answer I don't even know what the question is" My world - Metallica
--
-Ashish
--------------------------------------------------------------------------
Hi! I'm a shareware signature! Send $5 if you use me, send $10 for manual! http://www.123ashish.com http://www.softwarefreaks.com
"Ashish" <as*****@hotmai l.com> wrote... "Unforgiven " <ja*******@hotm ail.com> wrote in message news:bd******** ****@ID-136341.news.dfn cis.de... Tim Mierzejewski wrote: How do I clear the text from my screen, other than a bunch of \n's or endl's?
C++ can not clear the screen, as indicated in the FAQ Victor pointed you to.
Huh? C++ can do a lot of things using the OS specific libraries. Dont say C++ cannot clear the screen. Instead, you should say standard C++ cannot clear the screen.
That's the only C++ we speak of here.
"Ashish" <as*****@hotmai l.com> wrote... "Victor Bazarov" <v.********@att Abi.com> wrote in message news:vf******** ****@corp.super news.com... "Ashish" <as*****@hotmai l.com> wrote... "Unforgiven " <ja*******@hotm ail.com> wrote in message news:bd******** ****@ID-136341.news.dfn cis.de... > Tim Mierzejewski wrote: > > How do I clear the text from my screen, other than a bunch of \n's or > > endl's? > > C++ can not clear the screen, as indicated in the FAQ Victor pointed you to.
Huh? C++ can do a lot of things using the OS specific libraries. Dont say C++ cannot clear the screen. Instead, you should say standard C++
cannot clear the screen. That's the only C++ we speak of here.
Thats what I said too... but dont misguide the OP by saying that C++
cannot
Misguide?
do this, or can do that. Guide him to an appropriate newsgroup. I am sure you understand that.
But in all honesty, C++ cannot clear the screen. It's some OS-
specific library call that does that. Or sequence of characters
output to console or ... But it is not a language thing. And,
by the way, while there exist extensions to the language created
by some eager compiler vendors, there is only one C++ -- Standard.
That's what we mean when we say "C++ cannot do that". Another
example: can C++ read files? Yes. Can C++ read JPEG files? Yes.
Can C++ read and display JPEG files? NO. Displaying them is not
a language feature. C++ cannot do that. Not standard, not any
other C++. The same with clearing the screen.
Guiding others to a particular newsgroup is a voluntary thing. If
you stop me in the street and ask whether I could give you a lift
to a town a thousand kilometres away, I'll probably say "No, sorry,
I cannot do that", but I am not obligated to explain to you all
possible options you have or direct you to a bus station. It is
up to you to figure that out. (Of course it might be mighty kind
of me to point you to a bus stop, and I _probably_ would do that
if I knew where you were going -- The OP just asked whether there
was a way to clear the screen except outputting newline characters,
and there isn't). See the point?
Anyway...
Victor
"Victor Bazarov" <v.********@att Abi.com> wrote in message
news:vf******** ****@corp.super news.com... "Ashish" <as*****@hotmai l.com> wrote... "Victor Bazarov" <v.********@att Abi.com> wrote in message news:vf******** ****@corp.super news.com... "Ashish" <as*****@hotmai l.com> wrote... > > "Unforgiven " <ja*******@hotm ail.com> wrote in message > news:bd******** ****@ID-136341.news.dfn cis.de... > > Tim Mierzejewski wrote: > > > How do I clear the text from my screen, other than a bunch of
\n's or > > > endl's? > > > > C++ can not clear the screen, as indicated in the FAQ Victor
pointed you > to. > > Huh? C++ can do a lot of things using the OS specific libraries.
Dont say > C++ cannot clear the screen. Instead, you should say standard C++ cannot > clear the screen.
That's the only C++ we speak of here.
Thats what I said too... but dont misguide the OP by saying that C++ cannot
Misguide?
do this, or can do that. Guide him to an appropriate newsgroup. I am
sure you understand that.
But in all honesty, C++ cannot clear the screen. It's some OS- specific library call that does that. Or sequence of characters output to console or ... But it is not a language thing. And, by the way, while there exist extensions to the language created by some eager compiler vendors, there is only one C++ -- Standard.
That's what we mean when we say "C++ cannot do that". Another example: can C++ read files? Yes. Can C++ read JPEG files? Yes. Can C++ read and display JPEG files? NO. Displaying them is not a language feature. C++ cannot do that. Not standard, not any other C++. The same with clearing the screen.
Guiding others to a particular newsgroup is a voluntary thing. If you stop me in the street and ask whether I could give you a lift to a town a thousand kilometres away, I'll probably say "No, sorry, I cannot do that", but I am not obligated to explain to you all possible options you have or direct you to a bus station. It is up to you to figure that out. (Of course it might be mighty kind of me to point you to a bus stop, and I _probably_ would do that if I knew where you were going -- The OP just asked whether there was a way to clear the screen except outputting newline characters, and there isn't). See the point?
Anyway...
Victor
I agree with you. But if you tell me that you cannot give me a lift to a
thown a thousand kilometers away doesnt mean that you should tell me that
there is no way I can go to that town. Thats what the other person did. He
said that C++ cannot... I am not saying that he or you HAVE to guide the OP
to an appropriate newsgroup, its voluntary ofcourse, but dont MISguide him
saying that it cannot be done. Get it?
--
-Ashish
--------------------------------------------------------------------------
Hi! I'm a shareware signature! Send $5 if you use me, send $10 for manual! http://www.123ashish.com http://www.softwarefreaks.com
"Victor Bazarov" <v.********@att Abi.com> wrote in message
news:vf******** ****@corp.super news.com... "Ashish" <as*****@hotmai l.com> wrote... "Victor Bazarov" <v.********@att Abi.com> wrote in message news:vf******** ****@corp.super news.com... "Ashish" <as*****@hotmai l.com> wrote... > > "Unforgiven " <ja*******@hotm ail.com> wrote in message > news:bd******** ****@ID-136341.news.dfn cis.de... > > Tim Mierzejewski wrote: > > > How do I clear the text from my screen, other than a bunch of
\n's or > > > endl's? > > > > C++ can not clear the screen, as indicated in the FAQ Victor
pointed you > to. > > Huh? C++ can do a lot of things using the OS specific libraries.
Dont say > C++ cannot clear the screen. Instead, you should say standard C++ cannot > clear the screen.
That's the only C++ we speak of here.
Thats what I said too... but dont misguide the OP by saying that C++ cannot
Misguide?
do this, or can do that. Guide him to an appropriate newsgroup. I am
sure you understand that.
But in all honesty, C++ cannot clear the screen. It's some OS- specific library call that does that. Or sequence of characters
And those OS-specific libraries cannot be used using C++. I get it now.
"Ashish" <as*****@hotmai l.com> wrote in message
news:bd******** ****@ID-75446.news.dfnc is.de... "Victor Bazarov" <v.********@att Abi.com> wrote in message news:vf******** ****@corp.super news.com... "Ashish" <as*****@hotmai l.com> wrote... "Victor Bazarov" <v.********@att Abi.com> wrote in message news:vf******** ****@corp.super news.com... > "Ashish" <as*****@hotmai l.com> wrote... > > > > "Unforgiven " <ja*******@hotm ail.com> wrote in message > > news:bd******** ****@ID-136341.news.dfn cis.de... > > > Tim Mierzejewski wrote: > > > > How do I clear the text from my screen, other than a bunch of \n's or > > > > endl's? > > > > > > C++ can not clear the screen, as indicated in the FAQ Victor pointed you > > to. > > > > Huh? C++ can do a lot of things using the OS specific libraries. Dont say > > C++ cannot clear the screen. Instead, you should say standard C++ cannot > > clear the screen. > > That's the only C++ we speak of here. > >
Thats what I said too... but dont misguide the OP by saying that C++ cannot
Misguide?
do this, or can do that. Guide him to an appropriate newsgroup. I am sure you understand that.
But in all honesty, C++ cannot clear the screen. It's some OS- specific library call that does that. Or sequence of characters output to console or ... But it is not a language thing. And, by the way, while there exist extensions to the language created by some eager compiler vendors, there is only one C++ -- Standard.
That's what we mean when we say "C++ cannot do that". Another example: can C++ read files? Yes. Can C++ read JPEG files? Yes. Can C++ read and display JPEG files? NO. Displaying them is not a language feature. C++ cannot do that. Not standard, not any other C++. The same with clearing the screen.
Guiding others to a particular newsgroup is a voluntary thing. If you stop me in the street and ask whether I could give you a lift to a town a thousand kilometres away, I'll probably say "No, sorry, I cannot do that", but I am not obligated to explain to you all possible options you have or direct you to a bus station. It is up to you to figure that out. (Of course it might be mighty kind of me to point you to a bus stop, and I _probably_ would do that if I knew where you were going -- The OP just asked whether there was a way to clear the screen except outputting newline characters, and there isn't). See the point?
Anyway...
Victor
I agree with you. But if you tell me that you cannot give me a lift to a thown a thousand kilometers away doesnt mean that you should tell me that there is no way I can go to that town. Thats what the other person did.
No. Using the same analogy, the other person told you that you
can't get to another town in Victor's car. He didn't say that
clearing of the screen cannot be done. He said that clearing of
the screen cannot be done with C++. Get it?
He said that C++ cannot...
And you think that C++ can? Show me.
I am not saying that he or you HAVE to guide the OP to an appropriate newsgroup, its voluntary ofcourse, but dont MISguide him saying that it cannot be done. Get it?
Do you understand the difference between "it cannot be done" and
"it cannot be done using C++ means"? Saying the latter does NOT
imply the former, and in no way is misguiding. Get it?
"Victor Bazarov" <v.********@att Abi.com> wrote in message
news:vf******** ****@corp.super news.com... "Ashish" <as*****@hotmai l.com> wrote in message news:bd******** ****@ID-75446.news.dfnc is.de... "Victor Bazarov" <v.********@att Abi.com> wrote in message news:vf******** ****@corp.super news.com... "Ashish" <as*****@hotmai l.com> wrote... > > "Victor Bazarov" <v.********@att Abi.com> wrote in message > news:vf******** ****@corp.super news.com... > > "Ashish" <as*****@hotmai l.com> wrote... > > > > > > "Unforgiven " <ja*******@hotm ail.com> wrote in message > > > news:bd******** ****@ID-136341.news.dfn cis.de... > > > > Tim Mierzejewski wrote: > > > > > How do I clear the text from my screen, other than a bunch
of \n's > or > > > > > endl's? > > > > > > > > C++ can not clear the screen, as indicated in the FAQ Victor pointed > you > > > to. > > > > > > Huh? C++ can do a lot of things using the OS specific libraries. Dont > say > > > C++ cannot clear the screen. Instead, you should say standard
C++ cannot > > > clear the screen. > > > > That's the only C++ we speak of here. > > > > > > Thats what I said too... but dont misguide the OP by saying that C++ cannot
Misguide?
> do this, or can do that. Guide him to an appropriate newsgroup. I am sure > you understand that.
But in all honesty, C++ cannot clear the screen. It's some OS- specific library call that does that. Or sequence of characters output to console or ... But it is not a language thing. And, by the way, while there exist extensions to the language created by some eager compiler vendors, there is only one C++ -- Standard.
That's what we mean when we say "C++ cannot do that". Another example: can C++ read files? Yes. Can C++ read JPEG files? Yes. Can C++ read and display JPEG files? NO. Displaying them is not a language feature. C++ cannot do that. Not standard, not any other C++. The same with clearing the screen.
Guiding others to a particular newsgroup is a voluntary thing. If you stop me in the street and ask whether I could give you a lift to a town a thousand kilometres away, I'll probably say "No, sorry, I cannot do that", but I am not obligated to explain to you all possible options you have or direct you to a bus station. It is up to you to figure that out. (Of course it might be mighty kind of me to point you to a bus stop, and I _probably_ would do that if I knew where you were going -- The OP just asked whether there was a way to clear the screen except outputting newline characters, and there isn't). See the point?
Anyway...
Victor
I agree with you. But if you tell me that you cannot give me a lift to a thown a thousand kilometers away doesnt mean that you should tell me
that there is no way I can go to that town. Thats what the other person did.
No. Using the same analogy, the other person told you that you can't get to another town in Victor's car. He didn't say that clearing of the screen cannot be done. He said that clearing of the screen cannot be done with C++. Get it?
He said that C++ cannot...
And you think that C++ can? Show me.
I am not saying that he or you HAVE to guide the OP to an appropriate newsgroup, its voluntary ofcourse, but dont MISguide
him saying that it cannot be done. Get it?
Do you understand the difference between "it cannot be done" and "it cannot be done using C++ means"? Saying the latter does NOT imply the former, and in no way is misguiding. Get it?
Oh, why am I arguing with you anyways? I reinstalled my OS and lost all the
news and email filters. Time to ignore you and Dan Poop again. Goodbye. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: NeoPhreak |
last post by:
How would you clearn the screen in a console program???
Thanks
NeoPhreak >.<
|
by: Peter |
last post by:
I am just trying to learn python, to use for some fairly basic command
line utilities which will run in either Windows/DOS or Linux. I cannot
find a platform neutral way of manipulating the screen. I don't want
to do anything complex, but just:-
1. Clear the screen
2. Print a string at an arbitrary x,y position
3. Receive a single key stroke
It seems that under Linux the curses module will do all this and more
|
by: ritchie |
last post by:
Hi,
I am trying to clear the screen in my program.
I am loking for something that will work on all compilers, especially
Borland & MS Visual Studio 6.
On Visual studio I used 'system("cls");' and this works fine but this
won't work for Borland.
On Borland I used 'clrscr() ' function and it worked ok, but not for
Visual Studio.
|
by: John |
last post by:
Hi
I have the following in a Perl script. I just want to "clear screen" but it
does not work.
I don't think I've got my client and server sides confused.
Any ideas?
<SCRIPT Language="JavaScript">
moveTo (0,0);
|
by: REDBAIT |
last post by:
Hi Guys,
Am using Windows 2000 and Dev C++ to create C programs. I'm trying to use clear screen and other graphic functions such as positioning output on screen. Have seen some documents that suggest i use curses.h or system("clear") for clear screen, for example but all this has failed.
| |
by: sajithamol |
last post by:
I have an Applet that has three buttons on it, one being a clear screen button. I have it setup right now so it draws a rectangle the size of the applet and fills it with the background color. But when it does that my other two buttons disappear until I mouse over them again. Is there a better way to clear screen or anyway for the buttons to show back up after the "clear screen"?
|
by: owl |
last post by:
and here I thought I was going to finally be able to change the world
AND contribute back to python with my amazing clear screen extension -
but I can't get it to work. ;(
Copying from ZoomHeight.py and someone else's clever print suggestion:
-------------------------------------------------
# My Clear extension: clear a window
class Clear:
|
by: pbd22 |
last post by:
Hi.
Does anybody know how to issue a clear screen command like DOS "cls"
in a telnet session?
Thanks!
|
by: Kid Programmer |
last post by:
Hello guys. I was wondering how you can clear the screen in a java program. Here is the code for my program:
import javax.swing.SwingUtilities;
import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.BorderFactory;
import java.awt.Color;
import java.awt.Dimension;
import java.awt.Graphics;
public class GUI {
|
by: sganeshsvk |
last post by:
i want to clear the screen command prompt for mysql in windows XP...
In linux we use (CTRL + L) for clear the screen in mysql prompt....
i already use this command ( \c ) then ( \! clear ) for clear screen in Mysql windows XP...
Plz sir,
i want reply must......
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |