If you mean that arg1 and arg2 are two variables inside your C++ program, then you need to format them into the command string that you pass to the system function. Keep in mind that this is a
very crude example, just to get you started thinking, but:
Code:
char buffer[200];
int arg1, arg2;
arg1 = 2000;
arg2 = 10;
sprintf(buffer, "sh ./shellscript %i %i", arg1, arg2);
system(buffer);
I think this will get you started, but if not feel free to post again.
-PatP