ChildControl Property

Applies to TestComplete 14.40, last modified on April 22, 2021

Returns the child component by its index.

Declaration

componentObj.ChildControl(Index)
Read-Only Property A user form component object
Parameters
componentObj     One of the user forms components listed in the Applies To section  
Index [in] Required Integer

Applies To

The property applies to the following components:

TBevel, TcxButton, TcxButtonEdit, TcxCalcEdit, TcxCheckBox, TcxCurrencyEdit, TcxDateEdit, TcxGroupBox, TcxLabel, TcxListBox, TcxMemo, TcxMRUEdit, TcxProgressBar, TcxRadioGroup, TcxSpinEdit, TcxTextEdit, TcxTimeEdit, TImage, TObjectPicker, TPanel, TRectObjectPicker, TShape

Description

Use ChildControl to obtain the child component specified by its index. The total number of the component’s children is specified by the ChildControlCount property.

You can also obtain the child component by its name, using the ChildControlByName property.

Parameters

The property has the following parameter:

Index

The index of the desired child component. The index is zero-based: the first child has index 0, the second - 1, and so on. The index of the last child is ChildControlCount - 1.

Property Value

A child component which has the specified index.

Remarks

If you use Python or DelphiScript, you should enclose the parameter of the ChildControl property in square brackets: ChildControl[Index].

See Also

ChildControlByName Property
ChildControlCount Property

Highlight search results