Log in

View Full Version : Command Line parameters "Grabber"?


Rockas
8th February 2006, 13:34
Anyone knows of a program that can "grab" command line parameters sent by a CLI?

Thanks in advance.

stax76
8th February 2006, 13:44
Please elaborate, Process Explorer, another essential SysInternals tool might be what you are looking for.

Rockas
8th February 2006, 15:11
First of all thank you :)
Please elaborate
Well... Imagins you have an exe that supports Command line parameters, right?

Then I create an Interface that will send those parameters(commands)... but those commands are base upon internal(my interface) variables... so what I need is something that can get the "command line" sent by my interface just to check if everything is as I meant to be... I know that there are many ways that I can use to check that... but if there's an app out there that can make it it will be much easir for me to track down some possible errors.

Thanks

foxyshadis
8th February 2006, 16:12
in C:

for(i=0;i<argc;i++) print("%s",argv[i]); printf("\n");

Some languages have commands to access the entire command-line in one bite, but I think C only does in system-specific routines.

niknik
8th February 2006, 17:49
I did a program to do just that a few years back - couldn't find it though. :(

I would then rename my exe to match the "original" program, and it would then show whatver parameters were passed, after which it would send them to the original renamed program.

If you're coding the interface program, you can easily create a new program to do that, show the parameters on a form/or DOS box, and carry on.
(or better yet, you can show the actual parameters you're assembling to pass to the command line program, in a status bar, or message box, etc)

Rockas
8th February 2006, 19:13
Thanks for the suggestions guys... anyway... stax's suggestion is a supperb free application...

for those who might need something like this, here's the link:
http://www.sysinternals.com/Utilities/ProcessExplorer.html

again... thank you all

niknik
8th February 2006, 20:03
All utils from sysinternals are great. :)

niknik
8th February 2006, 20:04
... and nice to see there are Portuguese users here. ;)

Rockas
8th February 2006, 23:33
... and nice to see there are Portuguese users here. ;)
Yes... for quite a while :)