I have an application that calls a console based application when I open a file. I would like to somehow "spy" on this console application so that when it gets called I would like to see what command line parameters are being passed to this console app.
Is this possible?
For Windows, Use Process Explorer. Once PE is running, go to the
View
menu and select theSelect Columns
item. On that dialog, check theCommand Line
checkbox and click ok. You should see command line arguments for each process in Process Explorer now.For most Unix or OS X systems, doing
ps auxw
will print all processes on the system along with the command line arguments passed to them. Look up the man page for ps on your particular OS for more information on ps and what options you can pass to it to change its output.Since you say "exe", you're likely on windows. If that is the case Process Monitor would show you exactly what you need and more: http://technet.microsoft.com/en-us/sysinternals/bb896645.aspx