How to view the programme before it disappears

This is a discussion on How to view the programme before it disappears within the C Programming forums, part of the General Programming Boards category; Whenever I compile and run a programme, a black screen appears showing what the programme has done. But before I ...

  1. #1
    Registered User
    Join Date
    Mar 2008
    Posts
    1

    Question How to view the programme before it disappears

    Whenever I compile and run a programme, a black screen appears showing what the programme has done. But before I can even read a single word on that screen it just vanishes immediately.

    Some one told me that this might be due to very fast processing speeds of contemporary CPUs.

    So is there any way I can at least see what my programme has done i.e. can someone tell me how to make that black screen not go away immediately.

    I have heard that you can type getch() at the end of your programme, which means that the output screen does not go away until you press a character.

  2. #2
    Jack of many languages Dino's Avatar
    Join Date
    Nov 2007
    Location
    Katy, Texas
    Posts
    2,309
    Yes, you can use getch() or getchar(). Or, you can run the program from the command prompt (instead of running it from your IDE), and the command prompt won't go away.

    Todd
    Mac and Windows cross platform programmer. Ruby lover.

    Quote of the Day
    12/20: Mario F.:I never was, am not, and never will be, one to shut up in the face of something I think is fundamentally wrong.

    Amen brother!

  3. #3
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    21,310
    C + C++ Compiler: MinGW port of GCC
    Version Control System: Bazaar

    Look up a C++ Reference and learn How To Ask Questions The Smart Way

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Tree View control not appearing
    By Garfield in forum Windows Programming
    Replies: 1
    Last Post: 03-07-2004, 12:47 PM
  2. Gui Programme does'nt Compiles from DOS
    By Shadowhunt in forum C++ Programming
    Replies: 1
    Last Post: 06-06-2003, 08:05 AM
  3. Set View Position in CEditView :: MFC
    By kuphryn in forum Windows Programming
    Replies: 1
    Last Post: 05-21-2002, 09:27 PM
  4. Determining Active View :: MFC
    By kuphryn in forum Windows Programming
    Replies: 0
    Last Post: 04-25-2002, 07:34 PM
  5. How to open two view i MFC
    By Unregistered in forum Windows Programming
    Replies: 0
    Last Post: 02-05-2002, 03:13 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21