Keyboard.AsyncOptionKey

From Xojo Documentation

Read-Only Property (As Boolean )
BooleanValue = aKeyboard.AsyncOptionKey

Supported for all project types and targets.

If True, the Option key (macOS) or Alt key (Windows and Linux) is depressed.

Sample Code

The following code detects whether the Option key on Macintosh was depressed.

If Keyboard.AsyncOptionKey Then
// handle the keyboard event here....
MessageBox("keyboard event detected...")
End If