Vcl.Menus.TMenuItem.RadioItem

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property RadioItem: Boolean read FRadioItem write SetRadioItem default False;

C++

__property bool RadioItem = {read=FRadioItem, write=SetRadioItem, default=0};

Properties

Type Visibility Source Unit Parent
property published
Vcl.Menus.pas
Vcl.Menus.hpp
Vcl.Menus TMenuItem

Description

Specifies whether the menu item is mutually exclusive with other menu items in its group.

Use RadioItem to make the menu item behave like a radio button with a group of other menu items. The group of menu items is the set of all menu items in a pop-up or drop-down menu that have the same value of GroupIndex. When RadioItem is true, only one menu item in the group that contains the menu item can be checked at a time. The single selected menu item in the group is indicated by a round dot next to the Caption.

Note: RadioItem does not automatically select the item when the user clicks it at runtime: you must still explicitly set the Checked property to true in response to the OnClick event. RadioItem simply changes the appearance of the Checked state (from a check mark to a round dot) and automatically unchecks other menu items in the same group when you set the Checked property to true.

RadioItem does not work for the top-level items in a main menu.

Note: Under Windows NT 3.51, the round dot indicator only appears if the "new shell" has been installed.

See Also