usbrubberducky-payloads/payloads/examples/Conditions/Conditions-example2.txt

1 line
804 B
Plaintext
Raw Normal View History

REM The ELSE statement is an optional component of the IF statement which will only execute when the IF statement condition is FALSE. One way to interpret an ELSE statement is to read it as "IF this condition is true, THEN do this thing, or ELSE do another thing". REM Example IF THEN ELSE IF ( $_CAPSLOCK_ON == TRUE ) THEN STRING Capslock is on! ELSE IF ( $_CAPSLOCK_ON == FALSE ) THEN STRING Capslock is off! END_IF REM The condition of the capslock key, as determined by the target operating system, is checked. REM If the caps lock key state has been reported by the target as ON, the string "Capslock is on" will be typed. REM Otherwise, if the capslock key state has not been reported by the target (or it has been reported as not being on), the string "Capslock is off" will be typed.