ExpandGroup Action (Specific to DevExpressQuantumGrid Controls)

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

Description

Depending on the Expand parameter, the ExpandGroup action expands or collapses the specified grid group. The effect is the same as when you click the “+” (or “-”) button of the group. However, the ExpandGroup action does not move the mouse cursor.

Declaration

TestObj.ExpandGroup(GroupViewExpand)

TestObj A variable, parameter or expression that specifies a reference to one of the objects listed in the Applies To section
Group [in]    Required    Integer    
View [in]    Optional    Variant Default value: 0   
Expand [in]    Optional    Boolean Default value: True   
Result None

Applies To

The method is applied to the following objects:

View Mode

To view this method in the Object Browser panel and in other panels and dialogs, activate the Advanced view mode.

Parameters

The method has the following parameters:

Group

Specifies the zero-based index of the desired group. The first group has index 0, the second - 1, and so on. Index of the last row is wGroupCount - 1.

View

Specifies the grid view that contains the group. You can enter the view’s zero-based index or its caption.

The caption can contain asterisk (*) or question mark (?) wildcards or regular expressions. The asterisk corresponds to a string of any length (including an empty string), the question mark corresponds to any single character (including none). To specify more complicated parts of a caption, use regular expressions.

The caption can be case-sensitive or case-insensitive depending on the value of the Use case-sensitive parameters project setting.

The default value of the View parameter is 0 and corresponds to the leftmost view in the current grid level.

Expand

Specifies whether to expand or collapse the group.

Result Value

None.

Remarks

If the specified group is not found, ExpandGroup fails and posts an error message to the log.

The script recorder recognizes mouse clicks on the “-” buttons within the control groups and records the ExpandGroup command.

To collapse the group, you can either call the CollapseGroup action or call ExpandGroup with the Expand parameter set to False.

Example

To view an example that demonstrates how to use the ExpandGroup action, see Expanding and Collapsing Rows in Developer Express QuantumGrid.

See Also

CollapseGroup Action (Specific to DevExpressQuantumGrid Controls)

Highlight search results