Sending Keyboard Keys

Several plugins support sending a specific keyboard keys through its MScript functions. This allows your model to interact with AUT using keyboard keys. Typically you will send CTRL, SHIFT, ALT, TAB, ENTER, F1, F2, ….

Depending on the plugin implementation, you may specify one or many function keys in an MScript call. Some MScript function may support modifier keys which are just subset of keyboard keys and thus you will use the same key codes.

Keyboard keys must be enclosed with a pair of square brackets as shown below:

[KEYS.keyCode]

where keycode is the name assigned to the key.

Keyboard Key Codes

  • [KEYS.CONTROL] - CONTROL
  • [KEYS.CTRL] - CONTROL
  • [KEYS.ALT] - ALT
  • [KEYS.WIN] - WINDOWS
  • [KEYS.SHIFT] - SHIFT
  • [KEYS.SPACE] - SPACE
  • [KEYS.ENTER] - ENTER
  • [KEYS.TAB] - TAB
  • [KEYS.ESC] - ESCAPE
  • [KEYS.F1] - F1
  • [KEYS.F2] - F2
  • [KEYS.F3] - F3
  • [KEYS.F4] - F4
  • [KEYS.F5] - F5
  • [KEYS.F6] - F6
  • [KEYS.F7] - F7
  • [KEYS.F8] - F8
  • [KEYS.F9] - F9
  • [KEYS.F10] - F10
  • [KEYS.F11] - F11
  • [KEYS.F12] - F12
  • [KEYS.F13] - F13
  • [KEYS.F14] - F14
  • [KEYS.F15] - F15
  • [KEYS.F16] - F16
  • [KEYS.F17] - F17
  • [KEYS.F18] - F18
  • [KEYS.F19] - F19
  • [KEYS.F20] - F20
  • [KEYS.F21] - F21
  • [KEYS.F22] - F22
  • [KEYS.F23] - F23
  • [KEYS.F24] - F24
  • [KEYS.PAGE_DOWN] - PAGE_DOWN
  • [KEYS.PAGE_UP] - PAGE_UP
  • [KEYS.PAUSE] - PAUSE
  • [KEYS.UP] - UP
  • [KEYS.DOWN] - DOWN
  • [KEYS.LEFT] - LEFT
  • [KEYS.RIGHT] - RIGHT
  • [KEYS.NUM_LOCK] - NUM_LOCK
  • [KEYS.CAPS_LOCK] - CAPS_LOCK
  • [KEYS.SCROLL_LOCK] - SCROLL_LOCK
  • [KEYS.INSERT] - INSERT
  • [KEYS.DELETE] - DELETE
  • [KEYS.BACK_QUOTE] - BACK_QUOTE
  • [KEYS.BACK_SPACE] - BACK_SPACE