how do i make clrscr() work? my friend told me to include conio.c, but i think that my version of dev-c++ doesn't have that...so i tried downloading conio.c...but the problem is, clrscr() still doesn't work in my pc but it works in my friend's pc...we're both using dev-c++...
how do i make clrscr() work? my friend told me to include conio.c, but i think that my version of dev-c++ doesn't have that...so i tried downloading conio.c...but the problem is, clrscr() still doesn't work in my pc but it works in my friend's pc...we're both using dev-c++...
HI WEL I USE BORLAND C++. BUT IT IS SUPPOSED TO WORK ON ANY VERSION OF C++. JUST VERIFY THIS
1. ARE ALL YOOUR HEADER FILE ON A SINGLE FOLDER. MAYBE YOU COULD HAVE INSTALLED IT NOT PROPERLY.
IN TURBO C++ I USE #INLCUDE<CONIO.H>
AND I USE CLRSCR();
TRY IT ON YOUR DEV C++. BY THE WAY CAN ANYBODY TELL WATS THIS DEV C++. IS IT ANY DIFFERENT FROM TURBO OR BORLAND C++ :lol:
clrscr() is a presumptuous Borland fetish. Not every user of your program wants it!!!
In Dev C++ you can use system("CLS") to do the trick, the old DOS command. Include the stdlib.h for the system() function.
By the way, Dev C++ is a very nice IDE for a set of open source GNU compilers (mainly GCC and G++). The IDE comes in Windows and Linux versions. For Linux CLS has to be replaced with something else.
not at all a fetish, just overused by people that read tutorials by other people who abused it
There can be good reason to use it, for example if you were creating a fullscreen DOS application in Turbo Vision and wanted to clean up after yourself when terminating it.
Try to use 'fflush()' function with the argument 'stdout'.
When ever you want to clear your screen, just add this fflush(stdout). But remmember that it will fflush all standard out-put. But you use this. :cheesy:
Either the thread starter or a moderator has marked this thread as solved. You can most likely trust the responses and answers given. There is most likely no reason for any further responses to be posted here. If you have a related question, please start a new thread in this forum instead.
This thread is more than three months old
No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
This thread is currently closed and is not accepting any new replies.