Set Checkbox
The Set Checkbox action selects or clears a checkbox using its associated label.
When to Use
Use this action for options such as:
- Enable Notifications
- Accept Terms
- Remember Me
- Stay Awake
- Auto Sync
Syntax
var task = suremdmjs.automate().checkbox(
"<Package Name>",
"<Label Text>",
<true | false>
);
suremdmjs.automate().performAction(
task,
"onSuccess",
"onFailure"
);
Parameters
| Parameter | Description |
|---|---|
| Package Name | Target application package. |
| Label Text | Text displayed beside the checkbox. |
| Checked | true selects the checkbox, false clears it. |
Example
var task = suremdmjs.automate().checkbox(
"",
"Stay awake",
true
);
suremdmjs.automate().performAction(
task,
"onSuccess",
"onFailure"
);
Expected Result
The Stay awake checkbox is selected.