please can anyone tell me whether i can use command line arguments in c on windows xp
if so how
Printable View
please can anyone tell me whether i can use command line arguments in c on windows xp
if so how
you just posted a thread on this.... don't post the same thread twice!
the answer is YES.
how:
start>run>"cmd"
then...
cd c:\path\to\file\
then...
bla.exe ARG1 ARG2
--------------------------
bla.exe would be from your bla.c which would have
int main(argc, *argv[])
argc <-- number of arguments
argv <-- the arguments
process accordingly...
http://publications.gbdirect.co.uk/c...s_to_main.html
http://www.d.umn.edu/~gshute/C/argv.html
Same as here - http://cboard.cprogramming.com/showthread.php?t=92661