TextClick Method (TestObject)

Class

TestObject.

Action

Clicks in the center of the specified text.

Syntax

testObject.TextClick(text, [occurrence, clickType, modifiers, position, exactMatch])
Variable Description
text The text to be clicked. String.
occurrence Optional: Which occurrence of the text should be clicked, if there are multiple results. The first occurrence is 1. Integer.
clickType Optional: The desired mouse action. Default: left click. ClickType.
modifiers Optional: The modifier keys (Alt, Shift, Ctrl) to press while clicking. Default: Don't use modifier keys. ModifierKeys.
position Optional: The coordinates at which to click. The coordinates are relative to the the upper-left corner of the text. If no coordinates are specified the click is performed on the center of the text. Point.
exactMatch Optional: If true the text must completely match the captured text, otherwise a partial match is allowed. Boolean.