From Xojo Documentation

Property (As WebMenuItem )
aWebToolbarMenu.Menu = newWebMenuItemValue
WebMenuItemValue = aWebToolbarMenu.Menu

New in 2011r2

Supported for all project types and targets.

This property needs to be set to the menu to be displayed when the user clicks the item.


This example populate the WebToolbarMenus ChartsButton in the Open event of the WebToolbar:

// Create the chart menu
Var chartMenu As New WebMenuItem
chartMenu.Append(New WebMenuItem("Line"))
chartMenu.Append(New WebMenuItem("Bar"))
chartMenu.Append(New WebMenuItem("Pie"))
chartMenu.Append(New WebMenuItem("-"))
chartMenu.Append(New WebMenuItem("3D Line"))
chartMenu.Append(New WebMenuItem("3D Bar"))
chartMenu.Append(New WebMenuItem("3D Pie"))

// Assign the menu to the WebToolbarMenu button by looking it up by name
WebToolBarMenu(Me.ItemWithName("ChartsButton")).Menu = chartMenu