| | |
Screen disappears immediately
![]() |
•
•
Join Date: Aug 2008
Posts: 3
Reputation:
Solved Threads: 0
Hello guys,
I m very much new on C. Need all of your help to improve. Right now I m getting one problem. I m writing the very basic program..
When I complie it is showing success. But when I Run this program its not showing me the dos screen properly. Just for a flash the dos screen coming and going off. Not getting the solution. Please help
John
I m very much new on C. Need all of your help to improve. Right now I m getting one problem. I m writing the very basic program..
C Syntax (Toggle Plain Text)
#include <stdio.h> int main() { printf("Hello World!\n"); return 0; }
When I complie it is showing success. But when I Run this program its not showing me the dos screen properly. Just for a flash the dos screen coming and going off. Not getting the solution. Please help
John
c Syntax (Toggle Plain Text)
#include <stdio.h> int main() { printf("Hello World!\n"); getchar(); /* waits until user enters a key if the standard input buffer doesn't contain any */ return 0; }
By the way blrjohn, you could also try and fire up a console and execute your program from there. It won't disappear then. I dunno on which OS you are, but guessing it's Windows (80% market share or something eh):
Go to:
Start -> Run
type in "cmd"
Hit enter.
Behold the almighty black screen with often blinking cursor!
Typing in "cd" and then a path will let you change your directory. Type in "help" if you're in need of more help. Mastering the console is pretty convenient for developers.
Go to:
Start -> Run
type in "cmd"
Hit enter.
Behold the almighty black screen with often blinking cursor!

Typing in "cd" and then a path will let you change your directory. Type in "help" if you're in need of more help. Mastering the console is pretty convenient for developers.
Last edited by Clockowl; Aug 12th, 2008 at 7:11 pm.
•
•
•
•
u can see ur result by pressing ctrl+f5 or u can see ur result by adding a simple "getch();"
in ur code...........................
Your suggestions are not an improvement upon what it has been discussed already.
Welcome to the forum.
Avoid chat rooms speaking format next time you post. We can afford full words in English. There's not restriction about saving bits over here.
Last edited by Aia; Aug 13th, 2008 at 1:58 am.
![]() |
Similar Threads
- JavaScript Fix (DaniWeb Community Feedback)
- memory management in wndows 2000 (Windows NT / 2000 / XP)
- Nothing Works (Internet connection) Please Help (Networking Hardware Configuration)
- Do they always get in...eventually?? (Viruses, Spyware and other Nasties)
- How do I prevent value and attribute delays? (JavaScript / DHTML / AJAX)
- Run command not working (Windows NT / 2000 / XP)
Other Threads in the C Forum
- Previous Thread: solving linear equation in turbo c
- Next Thread: extract max-min value from every column in array
| Thread Tools | Search this Thread |
* adobe ansi api array arrays binarysearch calculate centimeter char cm convert copyanyfile copypdffile cprogramme createcopyoffile createprocess() csyntax directory dynamic feet fflush file floatingpointvalidation fork forloop frequency getlasterror getlogicaldrivestrin givemetehcodez global graphics gtkgcurlcompiling gtkwinlinux hacking hardware highest homework i/o inches incrementoperators intmain() iso km linked linkedlist linux linuxsegmentationfault list locate logical_drives loopinsideloop. match matrix microsoft motherboard mqqueue mysql oddnumber odf open opendocumentformat openwebfoundation pattern pdf performance pointer posix power program programming pyramidusingturboccodes read recursion recv recvblocked repetition reversing scanf scheduling segmentationfault send shape single socketprograming socketprogramming stack standard strchr string suggestions test unix urboc user variable voidmain() whythiscodecausesegmentationfault win32api windows.h






