c LANGUAGE ANOTHER PROB

Status
Not open for further replies.

makarand

Broken In
Hey guys,
I use bloodshed c editor on your advice. I made a program for speed, distance and time. but when i use 'clrscr();' function it does not work. what is wrong.
another thing
How can i make the program work without opening the editor
 

sakumar79

Technomancer
First you should note that conio.h is a Borland extension, NOT a standard header, so Dev-C++ and MinGW are in no way required to support it. The MinGW included with Dev-C++ 4.9.9.1 comes with a very reduced version of conio.h (no clrscr, gotoxy, etc); if you need more then you can use the native Windows console functions.
In Dev C++ you can use system("CLS") to do the trick, the old DOS command. Include the stdlib.h for the system() function.
An unofficial DevC++ FAQ website also provides and maintains an updated version of conio (and also winbgim) at *www14.brinkster.com/aditsu/console/ - that may be what you are looking for.


Regarding your second question - please elaborate... Are you asking for command line compiling? If you who prefer to use your own editor, download the command-line version of MinGW at *csjava.occ.cccd.edu/~gilberts/mingw/ instead. If you asking about running compiled program outside the IDE, you should find the created executable and run it - I dont think you need the IDE to run it...

Arun
 
OP
M

makarand

Broken In
Thanks guys but how can i run turbo c on XP
d'you have any suggestions for that?
and yes i wanted to run the program outside the IDE
 

MysticHalo

Your Maker.
makarand said:
How can i make the program work without opening the editor

U dont need to open the editor once the program is compiled and linked. Just run the .exe file created, thats it.
If u want to use clrscr();, then get Borland cmd line compiler.
 

Garbage

God of Mistakes...
u can also create a Project in which u can include ur header, lib files in ur .exe file
 

ilugd

Beware of the innocent
try this. Include the standard library header file and use the system call. Messy, but works

#include <stdlib.h>
system("cls");
 
Status
Not open for further replies.
Top Bottom