command line arguments

im trying to get my program to take a string from the user and split it up into arguments and then have the program execute code depending on what the first argument is and how it relates to the arguments after it. argv doesnt seem to be working. if anyone can help with this problem please let me know! :)
Maybe you're not utilizing argv properly. Post the code you've got so far?
there's a lot of code, i'm using if statements with argv[0], argv[1], etc. whenever i write something to cout the argc, it always says 1, and when i try to print it to the screen, it gives the name of the file and nothing that ive entered into the command line.
it gives the name of the file and nothing that ive entered into the command line.


This seems dubious.

argc/argv would be giving you the full command line. You must be running from the commandline incorrectly.
Topic archived. No new replies allowed.