Lets the user make and toggle between an either/or choice.
Properties
Property | Type | Description |
---|---|---|
label (read-only) | string |
Specifies the text that will be displayed as the label of the control. |
text (required) | string | The text displayed to the right of the checkbox, that is, the text of the choice. |
checked (submitted) | boolean | The property used to set or access the selection state of the checkbox. |
Traits
Trait | Description |
---|---|
validation |
A collection of zero or more validation rules (validator elements) that evaluate user input in the control at
runtime, and prevent the user from submitting the form if the |
declarations |
A collection of zero or more variable declarations (let elements) that can be referenced in solution-wide query expressions. |
Remarks
Normally, the value of checked
can only be false if the
checkbox is not selected (this is the default value), or true if the user selects the
checkbox. If NULL
gets data-bound into checked
, the checkbox
will not be selected.
Sample
<form id='checkbox' menuName='Checkbox Sample' platforms='web' xmlns='http://schemas.mobilengine.com/fls/v1'> <checkbox id="chkboxKnoo" label="Select all that apply:" text="My hovercraft is full of eels."/> <checkbox id="chkboxFjoo" label="" text="Life is like a box of chocolates."/> <checkbox id="chkboxDzoo" label="" text="Computers don't make mistakes."/> </form>
A
set of checkbox
controls to start you thinking
A workflow script running in the Mobilengine Cloud would access the submission of the form above in the format below:
{... chkboxKnoo: {checked: true}, chkboxFjoo: {checked: true}, chkboxDzoo: {checked: true}, ...}
See the workflow script reference guide for more details on data type mapping.