Click to See Complete Forum and Search --> : Bloodshed DevC++ ide....
CPUmelter
09-14-2005, 12:52 AM
i just starting using this ide, and i noticed that when i run programs the dialog box appears for a split second and then disappears. Is there a way to keep it there to ensure my program is producing the correct output?
This question just came up in another thread for Visual Studio .NET 2003 (http://www.sharkyforums.com/showthread.php?t=274022). Maybe the replies there apply to DevC++? I haven't used anything but Visual Studio for several years now.
CPUmelter
09-14-2005, 11:59 PM
man still no response :(
Nick_B
09-15-2005, 01:34 AM
man still no response :(
Umm....there's a response right above your message....
You need to pause the code or run it from within a persistent command prompt window to see what's happening. If it just runs successfully it'll close the window immediately afterwards.
CPUmelter
09-19-2005, 01:39 AM
it was the "pause" command that someone mentioned, just in case anyone runs into the same problem.
Mancora
09-19-2005, 03:21 AM
i believe its
system("pause)";
Btw, I think youd find yourself much happier working with something like the Visual Studio C++ express (which is free right now due to it being in beta) than Dev C++, Dev C++ is a steaming pile of crap IMHO.
eshbach
09-19-2005, 10:43 AM
system("pause"); works, but it's not a great way to do it since you're calling a pause.exe that happens to come with most C++ environments...
a better way to halt execution after your code has finihsed is with a little loop like:
int c;
do{
cout<<"Press Enter To End..."<<endl;
c = getchar();
if(c == EOF) break;
} while(c != '\n');