Check box control with ability to have intermediate state in addition to set/unset.
| Property | Default Value | Description |
| id | empty | id (name) of the script data object associated with control |
| title | empty | title of the control. Will be taken if no variable is bound (variable in dialog storage with name corresponding to id property) |
| align | stretched | Alignment of the control |
| state | false | Checked state of the control. See list of available values below |
| State Value | Description |
| true | Checked state |
| false | Not checked |
| none | Intermediate state |
| checked | Checked state |
| unchecked | Not checked |
| indeterminate | Intermediate state |
| Event | Description |
| onclick | event handler (function name) to be called, if check box is clicked |
- tri_state_checkbox.hejs
var varStorage = new Storage();
var dialog_template =
'@<dialog title="Test Dialog" resizing="both"> \
<tri_state_checkbox id="check" title="Never show me anything ever again" state="none"/> \
<tri_state_checkbox id="check2" title="I will open message Box" onclick="OnClick"/> \
<group minwidth="75" minheight="23" uniform="true" align="center"> \
<button title="&OK" default="true" returnval="ok"/> \
<button title="&Cancel" returnval="cancel"/> \
</group> \
</dialog>@';
Output().writeln("Dialog 4 returns: " + dialog(dialog_template, varStorage));
function OnClick() {
alert("Control Text: " + this.Text + "\r\nControl Name: " + this.Name);
}