i found this on ahk forum
SetTitleMatchMode, 2 ; This let's any window that partially matches the given name get activated
#IfWinActive, Chrome
F1::MsgBox You are currently using Google Chrome
#IfWinActive, Notepad
F1::MsgBox You are currently using Notepad
#IfWinActive, Firefox
F1::MsgBox...