Thread: Dev-C++

  1. #1
    x4000 Ruski's Avatar
    Join Date
    Jun 2002
    Location
    Outer Space!
    Posts
    542

    Question Dev-C++

    I'm using Dev-C++ 4.x and when i do a console application (DOS) and use something like:
    cout << "Hello";
    He just says hello and exits very fast .. faster than you can even read it. Unlike in VC++, he used to say Press any key to continue/exit or whatever... How's that done?
    Thanks
    what does signature stand for?

  2. #2
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644
    Before return 0, put this:
    Code:
    system("PAUSE");

  3. #3
    Registered User
    Join Date
    Jun 2002
    Posts
    2

    Talking Thank you.Helped me alot.

    Thank you for that helpful reply.I had tried cin.get(); ,but to no avail.Now that I look at it,it makes sense tho.It would exit out right after I hit the enter key for my first input into my program,roflmao.My bad.But thanks for that system("PAUSE"); command alot man.Really helps me out with Dev now....

  4. #4
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644
    No prob......anyone think they should make a HELPFUL help file?

  5. #5
    Registered User
    Join Date
    Jun 2002
    Posts
    2

    I SURE do!

    The help files are horrible.They're more like "**** you up files".......

  6. #6
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644

    Re: I SURE do!

    Originally posted by Sauron
    The help files are horrible.They're more like "**** you up files".......
    Also, the links hardly work, exept for the "Beginner Tutorial"

  7. #7
    x4000 Ruski's Avatar
    Join Date
    Jun 2002
    Location
    Outer Space!
    Posts
    542

    Question Dev-C++

    Is it always that hard to create a window and some command buttons in Dev-C++ ?? Why dont they make the tools, just like in Borland and Microsoft? Won't it be easier to create Windows Applications??
    Thanks
    what does signature stand for?

  8. #8
    Registered User
    Join Date
    Jun 2002
    Posts
    8
    Hi! I'm totally new to this whole programming thing, so if this is a stupid question please forgive me
    I tried to use the system ("PAUSE") command like you suggested but when I compile the program I get an error message of :

    implicit declaration of function `int system(...)'

    I have no idea what that means so could anyone please help me?

  9. #9
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644
    Include these:
    stdlib.h
    stdio.h
    conio.h

    Also link to the conio.o file

  10. #10
    Registered User
    Join Date
    Jun 2002
    Posts
    8
    That worked, thanks! Altought I didn't link to the conio.o file it did work. How would I link to it anyway?

  11. #11
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644
    Originally posted by Zavatar
    That worked, thanks! Altought I didn't link to the conio.o file it did work. How would I link to it anyway?
    No prob...
    To link using Dev-C++ 4.0 & 4.1:
    1. Right click on the project name and go to project settings

    2. Go to "Further Linker Options" or soemthing like that, it'll be the first thing

    3. Type this: "conio.o" w/o the quotes

    For Dev-C++ 5.0 and up:
    1. Same as Dev-C++ 4.0 & 4.1

    2. The last box, type this:
    "C:\Dev-C++\Lib\conio.o" w/o quotes, and this is assuming that C:\Dev-C++\ is the directory, if not, then you'll have to change it.

  12. #12
    Registered User
    Join Date
    Jun 2002
    Posts
    8
    Thanks for all your help! I've already finished my first program ( something simple, of course, just a simple use of the Pithagorean Theorem)! I was wondering, is there a way to avoid getting that " Press any key to continue " message at the end of the program but at the same time still have the program wait for you to close the window?

  13. #13
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644
    Not unless you inplement (sp?) it yourself.

  14. #14
    Registered User
    Join Date
    Jun 2002
    Posts
    8
    Ah, in that case, it will have to wait a few months
    I copied the program to a floppy but when I tried to open it from the floppy it wouldn't work and my computer froze a couple of times. Does this mean I can't copy programs to disk?

  15. #15
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644
    You can, it might deal w/ your computer and stuff.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. New to Dev C++/<windows.h>...
    By Cilius in forum C++ Programming
    Replies: 3
    Last Post: 02-23-2005, 01:05 AM
  2. Glut and Dev C++, Programs not Quitting?
    By Zeusbwr in forum Game Programming
    Replies: 13
    Last Post: 11-29-2004, 08:43 PM
  3. openGL programming - From MSVC++ to Dev C++
    By WDT in forum Game Programming
    Replies: 3
    Last Post: 03-08-2004, 08:47 PM
  4. openGL programming - From MSVC++ to Dev C++
    By WDT in forum Game Programming
    Replies: 1
    Last Post: 03-08-2004, 05:19 PM
  5. DEV C++ Limitations?
    By Kirdra in forum Game Programming
    Replies: 3
    Last Post: 09-09-2002, 09:40 PM