Beginner C/C++

Moderators: None (Apply to moderate this forum)
Number of threads: 5428
Number of posts: 16949

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
Dos Window Settings Posted by tonybar2 on 2 May 2002 at 8:32 PM
hello all,

I was wondering how to set my dos window, so that it does not just flash on real quick when executing program?
I know about just putting a scanf
or using system("pause");(which only works in C for me?)

but isn't there a way i can change the dos window settings?

Report
Re: Dos Window Settings Posted by weicco on 2 May 2002 at 10:03 PM
: hello all,
:
: I was wondering how to set my dos window, so that it does not just flash on real quick when executing program?
: I know about just putting a scanf
: or using system("pause");(which only works in C for me?)
:
: but isn't there a way i can change the dos window settings?
:
:

There's no way to change those settings. OS creates DOS console for your program when it starts and destroys it when it stops. Only way is to add getch() or something like that at the end of the program so that program wouldn't end until user presses some button.
Report
Re: Dos Window Settings Posted by etlusk on 4 May 2002 at 11:47 AM
: : hello all,
: :
: : I was wondering how to set my dos window, so that it does not just flash on real quick when executing program?
: : I know about just putting a scanf
: : or using system("pause");(which only works in C for me?)
: :
: : but isn't there a way i can change the dos window settings?
: :
: :
:
: There's no way to change those settings. OS creates DOS console for your program when it starts and destroys it when it stops. Only way is to add getch() or something like that at the end of the program so that program wouldn't end until user presses some button.
:
If you mean that you are running a DOS program from WINDOWS and have this problem there is a way around it(or at least in WIN95).
Make a MSDOS icon on your desktop.(clik START - PROGRAMS -ACCESSORIES- then LEFT CLICK on MSDOS icon for a shortcut - MOVE icon to the desktop area)
RIGHT CLICK icon - CLICK properties (It then allows you to change all sorts of stuff)
You may have to run your program from a batch file, maybe not. Just check out the options and customize it to your needs. The PROGRAM option allows you to run COMMAND.COM and a batch file.
The Screen option allows you to change the WINDOW/FULL SCREEN.
It sound to me like your problem is that when the program terminates the window closes. Rather quickly too.
Good Luck





 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.