Jump to content

problem with wingethanndle, Wingetproccess ...

Recommended Posts


This is a piece of code I use to identify the PID and Process Name of the active window:

#include <Process.au3>
local $WHandle = WinGetHandle("[Active]")
local $WTitle = WinGetTitle($WHandle)
local $PID = WinGetProcess($WHandle)
local $Process = _ProcessGetName($PID)

Tooltip(StringFormat("WHandle(%s) WTitle(%s) PID(%s) ProcessName(%s) ", $WHandle, $WTitle, $PID, $Process))

However on some application, I am getting wrong PID/processName; It returns ApplicationFrameHost.exe when the process is clearly NOT it.

example: (sometimes when browsing folders)

WHandle(0x0002018E) WTitle(Photos) PID(3500) ProcessName(ApplicationFrameHost.exe)

where am I doing wrong?


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...