www.digitalmars.com         C & C++   DMDScript  

c++.windows.32-bits - __argv and __argc in DMC

reply Peter Thun <peter.thun gmx.net> writes:
Hi.

Some windows compilers like Visual C++ and MinGW offer __argv and __argc 
to access the command line arguments in "WinMain-applications".

I tried this on DMC but I get an "undefined identifier" error.

But after this I looked in tchar.h and found:

#define __targv		__argv
#define __targv		__wargv

Hmmm, did they forgot to delete this from the header-file or is there a 
possibility to use it?
Jul 22 2004
parent Peter Thun <peter.thun gmx.net> writes:
Peter Thun wrote:
 Hi.
 
 Some windows compilers like Visual C++ and MinGW offer __argv and __argc 
 to access the command line arguments in "WinMain-applications".
 
 I tried this on DMC but I get an "undefined identifier" error.
 
 But after this I looked in tchar.h and found:
 
 #define __targv        __argv
 #define __targv        __wargv
 
 Hmmm, did they forgot to delete this from the header-file or is there a 
 possibility to use it?
Oh sorry. Problem solved. I forgot to include windows.h. I didn't knew that this is required. :-) cya
Jul 22 2004