KeyToggleSet

Sets the state of a toggle key and returns the previous value.

Syntax:

KeyToggleSet(@key, value)

Parameters:

(i) @key the toggle key in question. Values may be one of:
@CAPSLOCK 
 for the CapsLock key
@NUMLOCK 
 for the NumLock key
@SCROLLLOCK
 for the ScrollLock key

(i) value The new value of the toggle key.
@OFF
   for the unset state
@ON 
  for the set state

Returns:

(i) Previous toggle state of the key It may be:
@ON   
Key was set
@OFF   
Key was not set

 

Use this function to alter the state of one of the toggle keys - the CapsLock, NumLock, and ScrollLock keys.

Example:


KeyToggleSet(@NUMLOCK, @ON)
KeyToggleSet(@CAPSLOCK, @ON)
KeyToggleSet(@SCROLLLOCK, @ON)
See Also:

KeyToggleGet, SendKey