|
From: Saundra S. <Sch...@ho...> - 2000-11-14 04:13:44
|
This seems to be a common question....I too had the same problem....I've
been using the following command before the return statement.
system("pause");
Basicaly the system call works with DOS commands like pause and cls. I
haven't tried others, but these two work to hold the screen and clear the
screen.
Sam
----- Original Message -----
From: Ioannis Vranos <no...@ya...>
To: <dev...@li...>
Sent: Monday, November 13, 2000 6:30 AM
Subject: RE: [Dev-C++] Starting out
>
> > -----Original Message-----
> > From: dev...@li...
> > [mailto:dev...@li...]On Behalf Of
> > VILAYA TOURS
> > Sent: Monday, November 13, 2000 3:20 AM
> > To: dev...@li...
> > Subject: [Dev-C++] Starting out
> >
> >
> > I am just starting out with C++. I have the Oleg Yaroshenko "The
> > Beginner's Guide to C++" and I am trying the first example. I am
> > using the
> > Dev-C++ 3.9. Problem is that the small program of:
> >
> > #include <iostream.h>
> >
> > void main()
>
> int main()
>
> > {
> > cout <<"Hello";
> > }
> >
> > flashes up and is gone straight away. I have tried making the
adjustmants
> > reccommended in the help and various other ideas but to no avail. I
know
> > this is simple, but what is the answer. Also which mode should I be
> > working in for the Oleg's book - cosole, MSDos, Windows, Empty???
>
> Open a command prompt window, enter in the directory of your program using
> cd /directory and run the executable from there. I think an autopause
> routine must be implemented in the execute option of Dev--C++. I had sent
> one written in C to Colin in the past. Colin, i think you should include
one
> in next version of Dev-C++ (Visual C++ has the same feature too). :)
> Another way is to #include <cstdlib> or #include <stdlib.h> and use the
> system("pause") command, or use getchar() or cin.get() or something else.
>
>
> Ioannis
>
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
>
> _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> http://lists.sourceforge.net/mailman/listinfo/dev-cpp-users
>
|