Ok, thanks for all your help, but the problem is, there can be anywhere from 1 to 3 switches, and I need to find out whether the switches are valid, for example, -e -f -g are all valid, yet so is -ef...
Type: Posts; User: k0z
Ok, thanks for all your help, but the problem is, there can be anywhere from 1 to 3 switches, and I need to find out whether the switches are valid, for example, -e -f -g are all valid, yet so is -ef...
Hmmm, but argv[0] is the program name, and 'bal' is what it is searching for inside the file input.cpp. I just want to be able to get the - switches. Thanks anyway.
Hi, I'm a bit of a newbie, I am doing a project for school and it needs to accept command line arguments. I know that I need to use argc and argv the problem is I need to be able to use anything from...