[Dev-C++] RE: rookie question... Getting the current directory// Win exe files do not run / Ansi C
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: <Ger...@ne...> - 2002-12-27 02:23:39
|
Message: 1
From: "Danny Roelofs" <dro...@ho...>
To: <dev...@li...>
Date: Thu, 26 Dec 2002 02:36:28 +0100
Subject: [Dev-C++] rookie question... Getting the current directory
This is a multi-part message in MIME format.
------=_NextPart_000_0014_01C2AC87.978DF2E0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Hi,
Just started today picking my programming hobby after 10 years when i =
used an amiga and a whole different programming
enviroment, i feel like a rookie again in the world of programming with =
c++ with dev4 & windows.....
Can someone tell me how to get the current directory, i think it would =
be something like this:
string test;
void main(void)
{
test =3D GetCurrentDir();
return 0;
}
But ofcourse, this doesnt work.... someone.. enlighten me..
i tryed all kinds of material but couldn't find something that worked =
with dev4 and i dont know where i have to find the problem.
thanks for your help
Danny.
//i dont know if its valid in C++, but with C, please do not void man()...
//it should return integer. otherwise, the behaviour is undefined. :)
Message: 7
Date: Thu, 26 Dec 2002 10:48:25 -0500
To: "Tri Nguyen" <tr...@ge...>, dev...@li...>
From: Matthews <dematthews@uwaterloo.c>
Subject: Re: [Dev-C++] Win exe files do not run / Ansi C or pure C
If I understand your problem corrrectly, you are unable to see the "Hello
world." message that is supposed to print out. To rectify this, add
#include <stdlib.h> and in the line preceeding the return 0 command add
system("PAUSE");
Also, I do not understand why you #included windows.h. There's no reason
to at all.
At 12:52 PM 26/12/2002 +0100, Tri Nguyen wrote:
Hej all,
I would like to learn C and make win exe.
I'm using Win98 SE and DevC++ version 4 (not the newest).
The installed dir is C:\dev-C++ with Ming compile system (incl. in the
package)
My problem is I can not se whether the exe file runs or not.
There are no error message after compiling.
The c files are just a "Hello world" print out.
All the files are in 2 zip files, one for proj03 and the second for proj04.
The second question is the different between Ansi C and C and which is most
suitable with DevC++.
Thanks a lot
TriMy,
---
//for your second question, on ANSI C. Actually the pure C your refering to
//is the ANSI C. It is the standard from which all implementations of the
//language is based. Borland, GCC, LCC, and MS VC++ supports this standards
//however lame or strong their implementations is. And of course, they also
//have their own extensions of the language.
__________________________________________________________________
The NEW Netscape 7.0 browser is now available. Upgrade now! http://channels.netscape.com/ns/browsers/download.jsp
Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/
|