Author Topic: Hotkey Keyboard Shortcuts on/off  (Read 1191 times)

Schneppekarl

  • Guest
Hotkey Keyboard Shortcuts on/off
« on: September 23, 2019, 09:45:44 AM »
Hey guys
I mainly using VA to program my Keyboard and i've got a problem...
I can't find a way to program a hotkey to turn the Function "Keyboard Shortcuts" on/off.

I've tryed to copy the code from a topic with a similar problem (Disable / Enable Joystick)
Begin Text Compare : [{STATE_JOYSTICKBUTTONS}] Equals '1'
    Disable Joysticks
Else
    Enable Joysticks
End Condition

and transformed it into: (The activating key is on my mouse)
Begin Text Compare : [{STATE_KEYBOARDBUTTONS}] Equals '1'
    Disable Hotkeys
Else
    Enable Hotkeys
End Condition

I've tryed {STATE_KEYBOARDBUTTONS}, {STATE_KEYBOARDSHORTCUTS}, {STATE_HOTKEYS},
but it always only turns the Keyboard Shortcuts on but not off.
17:38:52 - Keyboard shortcuts on
17:38:52 - Mouse : 'Keyboard on'
17:38:52 - Keyboard shortcuts on
17:38:52 - Mouse : 'Keyboard on'
17:38:52 - Keyboard shortcuts on
17:38:52 - Mouse : 'Keyboard on'
17:38:52 - Keyboard shortcuts on

Has anybody a idea how to fix this?

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4761
  • RTFM
Re: Hotkey Keyboard Shortcuts on/off
« Reply #1 on: September 23, 2019, 09:51:08 AM »
As neither "{STATE_KEYBOARDBUTTONS}", "{STATE_KEYBOARDSHORTCUTS}", or "{STATE_HOTKEYS}" are valid tokens, your condition will always return false (any curly brackets that are not part of a valid token will be stripped, and the literal text "STATE_HOTKEYS", for example, does not equal the literal text "1").

As listed in the documentation, the state of the keyboard shortcuts can be retrieved using the "{STATE_SHORTCUTS}" token.


To easily access the documentation, press F1 while VoiceAttack has focus to open VoiceAttackHelp.pdf in your default PDF viewer.

Schneppekarl

  • Guest
Re: Hotkey Keyboard Shortcuts on/off
« Reply #2 on: September 23, 2019, 10:36:42 AM »
Okay got it.

It works now, thank you for the help!