Sign in Join
FPDoc Onlineexperiment

TCustomTabControl.PageIndex property

Member of TCustomTabControlpublicIn unit ComCtrls

Ordinal position for the selected page on the tabbed control.

Declaration

pascal
property PageIndex: Integer read FPageIndex write SetPageIndex default - 1;

Description

PageIndex is an Integer property which indicates the ordinal position in the page list for the selected page object on the tabbed control. The default value for the property is -1 and indicates that a page/ tab is not active on the control.

Changing the value for the property causes the OnChange event handler to be signalled when nboDoChangeOnSetIndex has been included in the Options for the control. OnChange is not signalled at design-time - even when enabled in Options. The InternalSetPageIndex method is called to update the property value and the design-time flags for the control. The new value is also sent to the widgetset class instance.

No actions are needed or performed when PageIndex is set to -1, or when its value is larger than PageCount-1.

The value in PageIndex is used to determine the value for both the ActivePage and ActivePageComponent properties. Changing the value in either of these properties causes PageIndex to be updated (when allowed by Options and CanChangePageIndex).

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.