Ok all please help an OLD VAX Fortran programmer understand why this does not work.
The is idea is to read the command line and parse it so that i can extract a file name to record the data to. Also, i need to be able to get the other arguments to work. This segment of code was copied from a similiar vax fortran program.
input to command line >>>> dr /r grr1.dat /? /p 1 /s 9600
output==>>
recording data to: grr1.dat
port 1
baud rate 9600
at 12:43pm
int main(int argc, char* argv[])
{ int count;
printf("argument count %d \n",argc);
for( count = 0; count < argc; count++ )
{
printf( " argv[%d] %s\n", count, argv[count] );
if ( argv[count] == "/r" )
{
printf("call recording\n");
printf("file %s \n",argv[count+1]);
}
if ( argv[count] == "/?" ) printf("call usage\n");
}
return 0;