09-12-2007 04:55 AM
09-12-2007 05:24 AM
If you re using a latch action boolean, it ll automatically get set to False once the button value is read by your code, else it wont...
However, if you use a switch action boolean, you can use a local variable or a Value property node to set its value back to False.
The Value property node colur appears Green, if it is a Switch action boolean.
The Value property node colur appears Purple, if it is a Latch action boolean.
09-12-2007 05:25 AM
Hello,
we found it ourselves. 😉
With selecting a boolean control in the block diagram, a new method node can be created which resets the control back to its standard value. 🙂
09-12-2007 05:38 AM
It is nice to see you found it yourself.
But be aware that when you use a Method [Invoke] node, you somehow lose the control of setting the value by yourself in the code.
What you re using is the Reinit to Default method for a boolean.
Today, the default value of your boolean may be False. What if tomorrow another crazy developer sets it to True from the Rt Click menu option -->> Data Operations -->> Make Current Value Default ?
So. you cannot be sure what is the actual default value for that boolean [ for that matter, any control/indicator ].
So, it is better to use locals to set back to the value of our wish [ anywhere we want in the code].
Run the attached Vi & see to it...
09-12-2007 05:40 AM