I'm trying to use hotkeys in Adobe Acrobat, but so far nothing works.
For example:
Code: Select all
SetTitleMatchMode 2
#IfWinActive, Adobe Acrobat
c::
MsgBox, Test
#IfWinActive
Thanks in advance!
Code: Select all
SetTitleMatchMode 2
#IfWinActive, Adobe Acrobat
c::
MsgBox, Test
#IfWinActive
A demonstration of multiple coding errors is below.The #IfWin directives are positional: they affect all hotkeys and hotstrings physically beneath them in the script. They are also mutually exclusive; that is, only the most recent one will be in effect. Title matching behaviour is determined by SetTitleMatchMode as set in the auto-execute section. If more than one variant is eligible to fire, only the one closest to the top of the script will fire. The exception to this is the global variant (the one with no #IfWin criteria): It always has the lowest precedence; therefore, it will fire only if no other variant is eligible (this exception does not apply to hotstrings).
Code: Select all
MsgBox, 64, Game over, This is the end!
; ==== End of auto-execute section ====
#IfWinActive ahk_exe acrobat.exe
c::MsgBox, A tisket
SetTitleMatchMode 2 ; Unlabeled code following Return never executes
#IfWinActive Adobe Acrobat ; Does not apply if a previously defined context already matched
c::MsgBox, A tasket
#IfWinActive