Inputs
| Port | Type | Required | Description |
|---|---|---|---|
| On | Any | No | Sets the internal state to true. Evaluated as boolean (non-Nil = true). |
| Off | Any | No | Sets the internal state to false. Evaluated as boolean (non-Nil = true). |
The OnOff operation manages an internal boolean state controlled by two inputs: On and Off. The resulting state is output in a configurable format — String, Integer, or Boolean. When both inputs are active simultaneously, the state toggles.
With neither On nor Off connected the state never changes, and the Editor flags the Node with a warning frame. An On value equal to the Off value makes Out the same whatever the state, and the Editor marks both fields with an info mark.
Inputs
| Port | Type | Required | Description |
|---|---|---|---|
| On | Any | No | Sets the internal state to true. Evaluated as boolean (non-Nil = true). |
| Off | Any | No | Sets the internal state to false. Evaluated as boolean (non-Nil = true). |
Outputs
| Port | Type | Default | Description |
|---|---|---|---|
| Out | String, Integer, or Boolean | Formatted Initial State | Current state. Type follows the OnOff Type picker (Property-driven). |
Properties
| Name | Type | Default | Description |
|---|---|---|---|
| OnOff Type | StackedDataSet | String | Output format for the state: |
| String | Outputs configurable on/off strings: | ||
| On Value | String | "ON" | Value when state is true. |
| Off Value | String | "OFF" | Value when state is false. |
| Integer | Outputs configurable on/off integers: | ||
| On Value | Integer | 1 | Value when state is true. |
| Off Value | Integer | 0 | Value when state is false. |
| Initial State | Boolean | false | The initial boolean state when the task starts. |
| On Error | Combo | Stop this branch | Per-op On Error verb (Stop this branch / Continue with the last value / Continue with the fallback). See the Error Handling guide. |
State on Reload
Internal state and output are preserved across restarts within the configured time window. Persisted state takes priority over Initial State on reload. Saved state is discarded if the configured output type (String, Integer, or Boolean) changed. In that case the operation starts from Initial State.
false.true = active; false or Nil = inactive.Nil = active; Nil = inactive.| On | Off | Result |
|---|---|---|
true | false | State becomes true |
false | true | State becomes false |
true | true | State toggles |
false | false | State and output unchanged; path continues |
OnOff Type: Boolean On: true Off: false
State becomes true.
Out: true
OnOff Type: Boolean On: false Off: true (previous state was true)
State becomes false.
Out: false
OnOff Type: Boolean On: true Off: true (previous state was true)
Both active — state toggles.
Out: false
OnOff Type: String On Value: "OPEN" Off Value: "CLOSED" On: true Off: false
State becomes true, formatted as the On string.
Out: "OPEN"
OnOff Type: Integer On Value: 100 Off Value: 0 On: true Off: false
State becomes true, formatted as the On integer.
Out: 100