Keyboard.AltKey

From Xojo Documentation

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

New in 2005r1

Supported for all project types and targets.

If True, the Alt key on Windows and Linux and Option key on Macintosh was depressed when the current method or event handler began.

Example

This example detects the Alt or Option key. It is in the Action event of a Timer.

If Keyboard.AltKey Then
MessageBox("Option/Alt key")
End If