"ps -ef" in Windows

prasanta123's Avatar
Newbie Member

Can anyone point me as to how to write a Java/C code that displays "ps -ef" Linux like output with Windows SDK maybe on Symbian?
If anyone already has that kind of program, can it be relayed to me?

Thanks in advance
shabbir's Avatar, Join Date: Jul 2004
Go4Expert Founder
For those who are unaware of what ps command of linux does

PS peports the process status.
ps [-a] [-A] [-c] [-d] [-e] [-f] [-j] [-l] [-L] [-P] [-y] [ -g grplist ] [ -n namelist ] [-o format ] [ -p proclist ] [ -s sidlist ] [ -t term] [ -u uidlist ] [ -U uidlist ] [ -G gidlist ]

-e List information about every process now running.
-f Generate a full listing.

This can be done in C++ using the API EnumProcess. Here is the MSDN sample Enumerating All Processes