Re: Two instances

new topic     » goto parent     » topic index » view thread      » older message » newer message

Hi Don,
if the PID solution is not what you want, you could have your program search for itself/others using pstools.
Availible from http://technet.microsoft.com/en-us/sysinternals/bb896649.aspx
extract of the doc from the "pslist" utility, which is part of pstools:

pslist exp
would show statistics for all the processes that start with "exp", which would include Explorer.
-d Show thread detail.
-m Show memory detail.
-x Show processes, memory information and threads.
-t Show process tree.
-s [n] Run in task-manager mode, for optional seconds specified. Press Escape to abort.
-r n Task-manager mode refresh rate in seconds (default is 1).
name Show information about processes that begin with the name specified.
-e Exact match the process name.

pslist is a command line utility, so you would need to issue the command and grab the output.
Of course, I am assuming your program is windows based.
Hope this helps!

Regards,
Alan

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu