WebMenuItem.Enabled

From Xojo Documentation

Revision as of 19:09, 2 August 2019 by Gperlman (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Property (As Boolean )
aWebMenuItem.Enabled = newBooleanValue
or
BooleanValue = aWebMenuItem.Enabled

New in 2011r2

Supported for all project types and targets.

If True, the menu item is enabled.

Example

Add a contextual menu to a Label with one of the menu items disabled. This code is in the Shown event handler of a WebLabel:

Var base As New WebMenuItem

Var loadMenu As New WebMenuItem("Load")
base.Append(loadMenu)

Var saveMenu As New WebMenuItem("Save")
saveMenu.Enabled = False
base.Append(saveMenu)

Me.ContextualMenu = base