win32 process information, using win32 extension

Discussion in 'Python' started by Java and Swing, Oct 21, 2005.

  1. i need to get information about the processes running on a windows pc
    (98, 2k, xp)

    i can get the pid's using, win32process.EnumProcesses()...and I can get
    a handle on a process using an id..such as

    handle = win32api.OpenProcess(win32con.PROCESS_QUERY_INFORMATION, 0,
    pids[0])

    ...but how can i get the name of the process, path to process, etc. I
    have the win32 extensions (pywin32) on python 2.4.

    thanks.
     
    Java and Swing, Oct 21, 2005
    #1
    1. Advertising

  2. I started down the win32process path trying to solve the same problem. That
    only ended in misery for me.

    Try this recipie instead:
    http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/442477

    -Chris

    On Fri, Oct 21, 2005 at 07:12:34AM -0700, Java and Swing wrote:
    > i need to get information about the processes running on a windows pc
    > (98, 2k, xp)
    >
    > i can get the pid's using, win32process.EnumProcesses()...and I can get
    > a handle on a process using an id..such as
    >
    > handle = win32api.OpenProcess(win32con.PROCESS_QUERY_INFORMATION, 0,
    > pids[0])
    >
    > ..but how can i get the name of the process, path to process, etc. I
    > have the win32 extensions (pywin32) on python 2.4.
    >
    > thanks.
    >
    > --
    > http://mail.python.org/mailman/listinfo/python-list
     
    Chris Lambacher, Oct 24, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. rtm
    Replies:
    0
    Views:
    815
  2. Anand
    Replies:
    3
    Views:
    921
    Tim Daneliuk
    Nov 8, 2003
  3. Tim Golden
    Replies:
    0
    Views:
    464
    Tim Golden
    Oct 21, 2005
  4. Dirc
    Replies:
    1
    Views:
    436
  5. Qi Lu
    Replies:
    0
    Views:
    432
    Qi Lu
    Jul 14, 2008
Loading...

Share This Page