Issue
Script Program bindings added to the Watch window or the Binding Variables pane in Script Editor show NULL or a previous value compared to the value in the objects they are bound to.
Product Line
EcoStruxure Building Operation
Environment
- Building Operation Workstation
- Building Operation Automation Server
- Building Operation Enterprise Server
Cause
Consider the script program below:
The bindings (1) are as follows along with the current values (2) in the Watch pane:
The source objects all have a value, but the output Bind Value are NULL except for the first Bind Value.
Resolution
Since SBO 1.5 script program bindings are only updated when they are processed in the program body.
In the following picture, only BINDtest1 has a non NULL value since the program is sitting at line 1 which has a reference to BINDtest1.
The next picture shows the bindings after the script program has run through all the program lines. Notice that BINDtest5 is still NULL since it has never been referenced in the program's body.
Program bindings that are not been processed in the program body will have a value of NULL.
or
Program bindings that were processed in a previous line inside the program will not update to the latest value until the program goes to a line that references the binding again at which point its value will update.