This post from a few year ago shows an example of exactly what I want to do:
Open the window of an application that is running, but minimized to the Tray.
I copied in the text for the TrayIcons function into my autohotkey.ahk and adjusted the hotkey function like this:
Code: Select all
#!p::
DetectHiddenWindows, On
TI := TrayIcons( "greenshot.exe" )
StringSplit,TIV, TI, |
MsgBox, 0, TI, % TI, 1
uID := RegExReplace( TIV4, "uID: " )
Msg := RegExReplace( TIV5, "MessageID: " )
hWnd := RegExReplace( TIV6, "hWnd: " )
PostMessage, Msg, uID,0x0203,, ahk_id %hWnd% ; Double Click Greenshot Icon
DetectHiddenWindows, Off
return
I realize the TrayIcons() code is old, but is there any way to fix it so it can work with Windows 10?