List Running Programs under Windows

Joe Aspelund DarkPhantom at charter.net
Sun May 18 00:37:18 EDT 2003


DarkPhantom at charter.net (Joe Aspelund) wrote in message news:<c6755e11.0305141751.221f5636 at posting.google.com>...
> I am programming for Windows (Windows XP more specifically) and I am
> trying to genrate a list of the currently running programs. Similar to
> the "Processes" tab of "Task Manager". A little clarification of the
> program: I want it to change the way it runs depending on other
> programs that are currently running. I just need to generate a list of
> sorts.
> Thanks for any assistance.


I have tryed win32all but the ShowAllProcesses doesn't work
Have used this code
>>> import win32pdhutil
>>> win32pdhutil.ShowAllProcesses()

and everytime I get this error message:

Traceback (most recent call last):
  File "C:\Python\Testing.py", line 2, in ?
    win32pdhutil.ShowAllProcesses()
  File "D:\Python23\lib\site-packages\win32\lib\win32pdhutil.py", line
67, in ShowAllProcesses
    items, instances = win32pdh.EnumObjectItems(None,None,object,
win32pdh.PERF_DETAIL_WIZARD)
error: (-2147481646, 'EnumObjectItems for buffer size', 'No error
message is available')

Can anyone explain what this means and how to get it working, if
possible.
  Again thank you for any help.
And thank you to those who have helped already




More information about the Python-list mailing list