Visual Studio 2010 Debug not stopping at return 0;

Aug 16, 2011 at 7:46pm
Hello, I am beginning to learn C++ from books and in doing so preparing for college courses on the subject. Right now I am trying to get familiar with Visual Studio and make sure it's working.

I searched the issue but a plethora of different situations that cause it were extremely overwhelming, and after playing with a dozen different settings to no effect I posted here.

I am running the application as an administrator under Windows 7.

Start Debugging finds and stops at syntax errors correctly but at the end of my simple program - return 0; it does not stop and closes the win32 console application.

Start without debugging produces the expected "Press any key . . ."

No question is too stupid, but compared to much of the topics on here this one is... stupid. So pre-emptive apologies for that & any insight is much obliged.





Aug 16, 2011 at 9:35pm
Can you post the main function? I've never seen that kind of issue between release vs debug configs.
Aug 16, 2011 at 9:59pm
The IDE automatically stops with "Press any key . . ." when you run an app, but not when you debug it.
Aug 16, 2011 at 10:26pm
Ha. Well I guess they figured if you are debugging you can set breakpoints. Funny. So don't forget to set a breakpiont at the return 0; Stoooopid design.
Aug 17, 2011 at 3:06pm
Thanks a lot for that. I was tweaking hard because it seemed like VS08 didn't function that way.
Topic archived. No new replies allowed.