WebToolbar

From Xojo Documentation

Class (inherits from WebControl)


New in 2011r2

For desktop applications, see Toolbar.

Adds a toolbar to a WebPage.

Events
Closed MenuSelected Shown
ContextualMenuSelected Opening TitlePressed
Hidden Pressed


Properties
ContextualMenu LockBottom fa-lock-32.png Position
ControlID fa-lock-32.png LockHorizontal fa-lock-32.png Style
Enabled LockLeft fa-lock-32.png TabIndex
FullWidth LockRight fa-lock-32.png Title
Height LockVertical fa-lock-32.png Tooltip
Icon Name fa-lock-32.png Top
Indicator Page fa-lock-32.png Visible
Left Parent fa-lock-32.png Width


Methods
AddItem GotoURL RemoveItemAt
AddItemAt ItemAt SetFocus
Close LastItemIndex UpdateBrowser
ExecuteJavaScript RemoveAllItems
Enumerations
Positions

Notes

See the Pressed and MenuSelected events for example of how button clicks and menu selections are handled. See the Shown event handler for the code that populates the menu.

Examples

This code adds a nested menu to a menu button:

// Create the menu
Var chartMenu As New WebMenuItem
Var lineMenu As New WebMenuItem("Lines")
lineMenu.AddMenuItem(New WebMenuItem("Dotted lines"))
lineMenu.AddMenuItem(New WebMenuItem("Solid lines"))
chartMenu.AddMenuItem(lineMenu)

// Assign it to the button
Var chartButton As WebToolbarButton
chartButton.DropDownMenu = chartMenu

See Also

WebToolbarButton, WebToolbarItem, WebMenuItem, classes.