To download NI software, including the products shown below, visit ni.com/downloads.
Overview
This example shows how to programmatically trigger a Value Change event using Value (Signaling) control property.
Description
It can be very useful to force certain events to trigger programmatically at certain points in your program. In this example we want the Value Change events to be triggered at the beginning of the program. This can be useful if these events are used to set the values of indicators on the front panel. If there is no initial update, then the indicators will be blank at first. This example shows us how to get around that.
Requirements
Steps to Implement or Execute Code
Additional Information or References
VI Block Diagram
VI Front Panel
Caveats
The Value(signaling) property can't be used with latching buttons.
**This document has been updated to meet the current required format for the NI Code Exchange.**
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.
Instead of the case structure connected to the iteration terminal, it would seem more reasonable to just place the property nodes from case "0" case before the outer loop. It is also customary to create an event for the stop button and eliminate the timeout event unless it is needed for other things.
Often the two triggered event should execute in a certain order. This can be achieved easily by connecting all four via the error wire in the desired order. reading the value should be done with a local variable instead of a property node.
Since the LEDs remain TRUE, running a second time does not prove anything. I would set the VI option to "clear indicators when called"