Problem passing parameter with int argc, char* argv
Posted on 2005-04-14
I am trying to pass parameter to a prgram this is being compiled with gcc in windows and should under dos...
I have writtten:
int main(int argc, char* argv)
info(); // where info shows information related to the app
printf("\ Option was continue ");
else if (argv=="pause")
printf("\Option was paused");
printf(" Please give an option pause or continue);
printf("\n This is the value in argv: %s",argv);
I have tried it several times, but it alwasys goes straight to the else block, even insede I can display arg as an expected option puase or continue,
Am I doing something wrong with the if (argv=="continue")
or is there some other problem??