To download NI software, including the products shown below, visit ni.com/downloads.
Overview
This example shows how to fire an event in a subVI using VI Server.
Description
This example shows how to fire an event in a subVI using Vi Server. The main Vi dinamically launches the subVI using VI Server. It then toggles the boolean in the subVI using VI Server as well. To trigger the event i get a reference to the front panel of the subVI. I then get an array of the controls on the front panel. The index for the toggle button in the ssubVI is 1 so I index into the array of controls. I then write the boolean value to the value (signaling) property node of the control in the subVI. Non that for the example works correctly both VIs must be in the same folder.
Requirements
Steps to Implement or Execute Code
1. Run VI
2. Press Launch subVI
3. Press Fire Event In subVI
Additional Information or References
Main VI Block Diagram
**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.