-
May 17th, 2004, 12:06 AM
#1
MS-DOS apps
Whenever I compile a MS-DOS app, I have to add system("pause"); to the end. Otherwise, it just flashes and exits. When I run a pre-compiled app though, I can't add this. Is there anything I can do to stop it from happening?
It is better to die on your feet than to live on your knees.
-
May 17th, 2004, 12:16 AM
#2
You are referring to NT console mode applications, not DOS apps. They aren't the same.
The reason that the window disappears, is that once the process that created it dies, the window goes away.
If you are interested in seeing the output from such a program, just start it from a shell rather than explorer.
Slarty
-
May 17th, 2004, 12:39 AM
#3
Go to the start menu click "run"... type cmd in the run box and enter it, then navigate to your program with the "dir" and "cd *folder*" commands, or "cd .." to go up a level in your folder structure. When you are in the folder, just type the name of the program, if it is an .exe. When you navigate to it this way, it won't close the window when the program dies.
-
May 17th, 2004, 12:41 AM
#4
Thanks, it works fine now. :-)
It is better to die on your feet than to live on your knees.
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
|
|