Description
Description-Separate-1
Overview
These two Vis demonstrate how to use the Value (Signaling) Property in LabVIEW to interact with a main VI from a sub VI's front panel.
Description
LabVIEW allows event structures to be activated programmatically by using the Value (Signaling) Property.
If a sub VI's controls need to run code found in the event structure case of another VI's front panel object, the sub VI can alter the property by using control refnums passed from the main VI.
These two programs show a simple example of using event structures and control refnums to generate a random number when a button is pressed on either front panel.
Please see the two documents below for explanations behind the property and mechanical actions of the controls necessary for the implementation of this code.
Requirements
- LabVIEW 2013 (or compatible)
Steps to Implement or Execute Code
- Open Main VI in the LabVIEW Project labeled Sub VI Button Press.
- Run the Main VI to start the program.
- Access the Sub VI front panel by using the button on the Main VI front panel.
Additional Information or References
VI Block Diagram
References
LabVIEW Help: Controlling Front Panel Objects Programmatically from a SubVI
LabVIEW Help: Changing the Mechanical Action of a Boolean Object
**This document has been updated to meet the current required format for the NI Code Exchange.**
Description-Separate-2