Class: cWebMenuItemCheckbox

Properties  Events  Methods    Index of Classes

The Web Framework checkbox menu item/toolbar item, can be used to create a multi-option menu

Hierarchy

cObject
---cWebObject
------cWebBaseUIObject
---------cWebMenuItem
------------cWebMenuItemCheckbox

Library: Web Application Class Library

Package: cWebMenuItemCheckbox.pkg

Description

The cWebMenuCheckbox can be used to create the illusion of a multi-option menu.



The pbChecked property indicates whether the item is checked or not. It is also a property that is synced, thus meaning that when a click is performed, the WebProperty is already set (to its new state) when the Event OnClick fires.

A special attribute of the cWebMenuItemCheckbox is that the menu does not automatically hide. This is because of the illusionistic multi-select behaviour in which you can select multiple items at one or "toggle" them. Which can be seen in the super-list column showing/hiding behaviours.

All inheritance from cWebBaseMenu_mixin.pkg (cWebMenuList, etc.) have an:
Procedure OnDefineMenu tWebMenuItem[] ByRef aMenu

The WebMenuItemCheckbox class uses the eChecked tWebMenuItem struct member. If you want to add a checkbox, a -1 indicates an unchecked checkbox and a 1 indicates a checked state, while a 0 (default) indicates no checkbox.

Icons on Checkbox Menu Items

A cWebMenuItemCheckbox and an icon at the same time are not officially supported nor encouraged (from (expected) design perspective).

Defining Checkbox Menu Items

When using OnDefineMenu, pbChecked is unavailable and thus the checked states need to be manually synced using UpdateItem.