SelCount Property

Applies to TestComplete 15.69, last modified on November 13, 2024

Returns the number of selected items in a multi-selectable list box

Declaration

componentObj.SelCount
Read-Only Property Integer
componentObj     One of the user forms components listed in the Applies To section  

Applies To

The property applies to the following components:

TcxListBox

Description

Use the SelCount property to determine the number of selected items in a multi-selectable list box (that is, whose MultiSelect property is True). If the list box does not support multiple selection, this property returns -1. In this case, you can use the ItemIndex property to get the selected item’s index.

Note: The SelCount property is not displayed among other TcxListBox properties in the User Forms editor. However, it is available in scripts and displayed in the Code Completion window.

Property Value

If the list box’s MultiSelect property is True, the SelCount property returns the number of currently selected list items. If the MultiSelect property is False, SelCount returns -1.

Remarks

To determine whether a particular list box item is selected, use the Selected property.

See Also

ItemIndex Property
MultiSelect Property
Selected Property

Highlight search results