ClickButton Action (Specific to Bootstrap Alert and Modal Controls)

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

Description

Use the ClickButton method to move the mouse pointer to the button specified by its caption or index among other buttons and then simulate a click over it.

Declaration

TestObj.ClickButton(Button)

TestObj A variable, parameter or expression that specifies a reference to one of the objects listed in the Applies To section
Button [in]    Required    Variant    
Result None

Applies To

The method is applied to the following objects:

View Mode

This method is available in the Object Browser panel and in other panels and dialogs in both Basic and Advanced view modes.

Parameters

The method has the following parameter:

Button

Specifies the needed button. You can enter the button’s index (from 0) 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.

Result Value

None.

Remarks

If the specified item was not found in the control, ClickButton fails and posts an error message to the test log.

See Also

wButtonCount Property (Web Controls)
wButtonText Property (Web Controls)

Highlight search results