Get window title/hwnd from process name?
Posted: 06 Jun 2014, 00:56
How can I do it?
Let's help each other out
https://www.autohotkey.com/boards/
Code: Select all
processName := "notepad.exe"
if (WinExist("ahk_exe " . processName)){
WinGetTitle, title, ahk_exe %processName%
MsgBox The title of the window is %title%
} else {
MsgBox The process "%ProcessName%" doesn't exist.
}