943,623 Members | Top Members by Rank

Ad:
  • C++ Discussion Thread
  • Unsolved
  • Views: 18388
  • C++ RSS
You are currently viewing page 1 of this multi-page discussion thread
Mar 18th, 2006
0

How to use Dev C++

Expand Post »
I cannot figure out how to open the results/output window in Dev c++. Also how to effectively use step over / step into . I kept breakpoints at certain points in my program but step over from then onwards does not happen by pressing ctrl+f7 and I dont know how to do it . I am using
Dev C++ 4.9.9.2 version .
Thanks ,
comwizz
Similar Threads
Reputation Points: 10
Solved Threads: 0
Light Poster
comwizz is offline Offline
39 posts
since Nov 2005
Mar 19th, 2006
0

Re: How to use Dev C++

Please reply.
Reputation Points: 10
Solved Threads: 0
Light Poster
comwizz is offline Offline
39 posts
since Nov 2005
Mar 19th, 2006
0

Re: How to use Dev C++

Quote originally posted by comwizz ...
Please reply.
Don't bump your thread. Everyone here is helping others on voluntary basis by finding whatever time they are free to spare.


Quote originally posted by comwizz ...
I cannot figure out how to open the results/output window in Dev c++. Also how to effectively use step over / step into . I kept breakpoints at certain points in my program but step over from then onwards does not happen by pressing ctrl+f7 and I dont know how to do it . I am using
Dev C++ 4.9.9.2 version .
Did you tried looking at the help file of DEV.
SpS
Reputation Points: 70
Solved Threads: 32
Posting Pro
SpS is offline Offline
598 posts
since Aug 2005
Mar 19th, 2006
0

Re: How to use Dev C++

>I cannot figure out how to open the results/output window in Dev c++.
Assuming I understand what you mean, the output window is a command prompt process that's created when you run your program and terminates when your program ends. Just hit F9 to compile and run, or choose the option you want from the Execute menu. But keep in mind that you'll need to use a trick to keep the window open long enough to read your output. The accepted solution is to ask for input:
C++ Syntax (Toggle Plain Text)
  1. #include <ios>
  2. #include <iostream>
  3. #include <limits>
  4.  
  5. void pause_program ( const char *msg )
  6. {
  7. std::cout<< msg;
  8.  
  9. // This might not work as advertised
  10. if ( std::cin.rdbuf()->in_avail() > 0 )
  11. std::cin.ignore ( std::numeric_limits<std::streamsize>::max(), '\n' );
  12.  
  13. std::cin.get();
  14. }
>Also how to effectively use step over / step into
I never liked Dev-C++'s debugging interface. I always drop down to the command line and use gdb directly rather than fiddle with it.
Administrator
Reputation Points: 6442
Solved Threads: 1393
Bad Cop
Narue is offline Offline
11,807 posts
since Sep 2004
Mar 19th, 2006
0

Re: How to use Dev C++

i use Dev C++ and a simple

int main() {
............
............

system ("pause");
return 0;
}

keeps the window open for me to see the results.
Reputation Points: 10
Solved Threads: 0
Newbie Poster
nemo is offline Offline
24 posts
since Feb 2006
Mar 19th, 2006
0

Re: How to use Dev C++

Quote originally posted by nemo ...
i use Dev C++ and a simple

int main() {
............
............

system ("pause");
return 0;
}

keeps the window open for me to see the results.
System Command- Non-Portable,Very Expensive
SpS
Reputation Points: 70
Solved Threads: 32
Posting Pro
SpS is offline Offline
598 posts
since Aug 2005
Mar 19th, 2006
0

Re: How to use Dev C++

Quote originally posted by sunnypalsingh ...
System Command- Non-Portable,Very Expensive
>Non-Portable
It is portable, since it's on my laptop I can carry it around with me everywhere I go. :rolleyes:

>Very Expensive
Didn't cost me a dime to use. :rolleyes:

Or am I just clutching at straws here.
Featured Poster
Reputation Points: 1536
Solved Threads: 431
Posting Expert
iamthwee is offline Offline
5,865 posts
since Aug 2005
Mar 19th, 2006
0

Re: How to use Dev C++

Quote originally posted by iamthwee ...
>Non-Portable
It is portable, since it's on my laptop I can carry it around with me everywhere I go. :rolleyes:

>Very Expensive
Didn't cost me a dime to use. :rolleyes:

Or am I just clutching at straws here.
If your intent was to make people laugh then I guess you succeeded...otherwise I pity on you.
SpS
Reputation Points: 70
Solved Threads: 32
Posting Pro
SpS is offline Offline
598 posts
since Aug 2005
Mar 19th, 2006
0

Re: How to use Dev C++

No I was being serious. But thank you for your pity.
Featured Poster
Reputation Points: 1536
Solved Threads: 431
Posting Expert
iamthwee is offline Offline
5,865 posts
since Aug 2005
Mar 19th, 2006
3

Re: How to use Dev C++

Quote originally posted by sunnypalsingh ...
System Command- Non-Portable,Very Expensive
Are you thinking of the same system() I'm thinking of? Are you thinking? system("PAUSE") is not expensive. The amount of time spent waiting for user input is about 3000000000000000000000000000000000000000000000000000000000000000000000000 times (give or take a few dozen powers of ten) as long as the amount of overhead that system() produces.

Portability is not an issue here; a command line program to be ported to other platforms would have the end-of-program wait-for-input removed anyway.
Team Colleague
Reputation Points: 1133
Solved Threads: 171
Super Senior Demiposter
Rashakil Fol is offline Offline
2,478 posts
since Jun 2005

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C++ Forum Timeline: C++ Random Numbers
Next Thread in C++ Forum Timeline: how to close one window.





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC