[Overview][Constants][Types][Classes][Procedures and functions][Index] Reference for unit 'StdCtrls' (#lcl)

TCustomListBox.Items

The list of all items defined in the control.

Declaration

Source position: stdctrls.pp line 646

public property TCustomListBox.Items : TStrings
  read FItems
  write SetItems;

Description

Items is a TStrings property which contains the string values (and associated objects) displayed in the list box control. Reading allows access to the contents of the list (TStrings compatible). Assign another string list to the property to replace the Items in the control. Internally, Items is cast to a TExtendedStringList type to access the item attribute data for the entries.

Use ItemIndex to access the selected item in the list box control. Use the Selected property to select or de-select values in Items when MultiSelect is enabled. Use SelectRange to select a range of Items in the control.

See also

TCustomListBox.ItemIndex

  

Ordinal position for the currently selected item, -1 if none.

TCustomListBox.Selected

  

The Selected state for an item in the control.

TCustomListBox.MultiSelect

  

Allows selection of more than one item from the list.

TCustomListBox.SelectRange

  

Changes the selection state for a range of Items in the control.

TStrings


Version 3.2 Generated 2024-02-25 Home