>>261
#IfWinActiveだと無理っぽいのぉ
#Ifなら出来た

#If (WinActive("ahk_exe notepad.exe") or WinActive("ahk_exe mspaint.exe"))
F1::
msgbox, ほにゃらら
Return
#If