wItemChecked Property (Android Controls)

Applies to TestComplete 15.69, last modified on November 13, 2024
This property is available in legacy mobile tests that work with devices connected to the local computer. To learn how to simulate user actions in newer cloud-compatible mobile tests, see the Simulating user actions in tests section.

Description

Use the wItemChecked property to determine whether the control item specified by the Item parameter is checked or unchecked.

Declaration

TestObj.wChecked(Item)

Read-Only Property Boolean
TestObj A variable, parameter or expression that specifies a reference to one of the objects listed in the Applies To section
Item [in]    Required    Variant    

Applies To

The property is applied to the following objects:

View Mode

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

Parameters

The property has the following parameter:

Item

Specifies the control item whose state you want to obtain. You can specify the item using its title or position on the control (from 0).

Property Value

True, if the specified item is checked, or False, if the item is unchecked.

Remarks

If the specified item is not found, wItemChecked returns the null value (Nothing in VBScript, nil in DelphiScript, None in Python, null in JavaScript, JScript, C++Script and C#Script) and posts an error message to the test log.

If you use Python or DelphiScript, you should enclose the parameters of the wChecked property in square brackets: wChecked[Item, ByPosition].

Example

To view an example that demonstrates how to use the wItemChecked property, see Checking the Action Bar Items' State.

See Also

About Testing Android Applications (Legacy)
Checking the Action Bar Items' State
CheckItem Action (Android Controls)
wIsItemCheckable Property (Android Controls)

Highlight search results