How to check on windows whether a particular process / application is running or not. As we know on unix we use "ps" command to check.
can I write small C/C++ program to check that?
Can anyone help me please?
if you install Windows XP Service Pack 2 Support Tools from
http://www.microsoft.com/downloads/details.aspx?familyid=49AE8576-9BB9-4126-9761-BA8011FABF38&displaylang=en
in the command line tools
http://commandwindows.com/supporttools.htm
there is a program pstat.exe which gives information about the processes and drivers that are currently running.
You could run pstat.exe using the system function, e.g.
-
system("pstat > pslist.txt"); /* call system */
-
and then search the output file pslist.txt for what you require