Archived

This topic is now archived and is closed to further replies.

quickly closing windos in devcpp...

This topic is 4951 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi and Im learning to program using C++, But I am having a major problem with DevC++. When I try to run my programs a black window just opens and closes within seconds and I cant stop it. Is there some kind of line of code that will pause or stop my screen from closing? -Thank you.

Share this post


Link to post
Share on other sites
In the top of your application, add in:

#include <conio.h>

And on the last line of your application, place this line:

getch(); // Wait for a key to be pressed


That''ll fix the problem

Share this post


Link to post
Share on other sites