954,535 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Processes

Hey guys,

Is there a was to show every process running using C++?

Or to see if "X" process is running?

Thanks

xdfear
Newbie Poster
1 post since Mar 2007
Reputation Points: 10
Solved Threads: 0
 

There is always a way.. :)

1. See "man -s 4 proc"
2. See "man -s 1 proc"

If you donno much abt this kinda programming, it might be easier if you run system("ps -eaf | awk ... > tmp.file") from C++ and then just parse this file.
"..." is appropriate arguments to awk depending on your requirements.

thekashyap
Practically a Posting Shark
811 posts since Feb 2007
Reputation Points: 254
Solved Threads: 75
 

U just hit Ctrl-Alt-Del ;)

WaltP
Posting Sage w/ dash of thyme
Moderator
10,506 posts since May 2006
Reputation Points: 3,348
Solved Threads: 944
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You