Thread: Running a program

  1. #1
    Registered User quiksilver9531's Avatar
    Join Date
    Nov 2001
    Posts
    36

    Running a program

    When I run a text program in ms dos..how do i keep the window from closing out when its finished...I know i can do go to the file manually thru msdos and it wont close but I want to know if theres something you can put in the code so it doesn't close when you when it from the file..Thanks

  2. #2
    Unregistered
    Guest

    Try this

    U can use system("PAUSE") but u have to include stdlib.h. It displays press any key to continue and waits for u to press a key to quit.

  3. #3
    Registered User quiksilver9531's Avatar
    Join Date
    Nov 2001
    Posts
    36
    Thanks can you post like an example code please Thanks

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Program running long
    By smarta_982002 in forum Windows Programming
    Replies: 3
    Last Post: 03-27-2008, 05:24 AM
  2. Running my program in the background
    By shoobsie in forum Windows Programming
    Replies: 4
    Last Post: 10-09-2005, 02:38 AM
  3. Replies: 3
    Last Post: 09-05-2005, 08:57 AM
  4. Why is my program running away?
    By badkitty in forum C++ Programming
    Replies: 4
    Last Post: 09-19-2001, 04:27 PM
  5. Running program
    By muffin in forum C Programming
    Replies: 5
    Last Post: 08-30-2001, 10:57 AM