Autohotkey application-specific hotkeys

前端 未结 1 1261
一个人的身影
一个人的身影 2021-01-12 15:17

I am a newbie to Autohotkey, and I can\'t figure this out despite reading through this site and the official documentation.

I just want to have certain hotkeys work

相关标签:
1条回答
  • 2021-01-12 16:07

    Try this and make sure you have the latest version of AutoHotkey. Put the application process name in the strYourAppExeName variable and put your hotkey definitions in the #if block.

    strYourAppExeName := "notepad.exe"
    strYourMessage := "``(grave)"
    
    #If WinActive("ahk_exe " strYourAppExeName)
        Space::SendInput, % strYourMessage
    #if
    
    0 讨论(0)
提交回复
热议问题