MobileScreen.ToolbarButtonPressed

From Xojo Documentation

You are currently browsing the old Xojo documentation site. Please visit the new Xojo documentation site!
Event


MobileScreen.ToolbarButtonPressed(button As MobileToolbarButton)

Supported on Mobile.

Called when a button on the left or right Navigation Bar or the Toolbar is pressed.

Sample Code

Check for a button pressed based on its caption:

Select Case button.Caption
Case "Save"
// call save code
Case "Edit"
// call edit code
End Select

Check for a button pressed based on its name:

Select Case button.Caption
Case SaveButton
// call save code
Case EditButton
// call edit code
End Select

Check for a button pressed based on its type:

Select Case button.Type
Case MobileToolbarButton.Types.Save
// call save code
Case MobileToolbarButton.Types.Edit
// call edit code
End Select