To download NI software, including the products shown below, visit ni.com/downloads.
This example demonstrates how to set and get values from controls and indicators of a dynamically called VI.
LabVIEW can link to subVIs by two different methods:
Statically linked subVIs are the normal subVIs that are dropped on the block diagram of the main VI. A statically linked subVI is loaded into memory at the same time the main VI is loaded.
With dynamic linking, subVIs are not loaded until specifically instructed by the code of the main VI. This enables the programmer to create applications which can exchange parts of the application during run-time.
This example shows one way to exchange data between the caller and the callee. To do so, the property node Set Control Value and Get Control Value is used.
Steps to Implement or Execute Code
Additional Information or References
Note: This example shows one possible way to transfer data to and from a dynamically called VI.
Depending on your application, there are many other ways to accomplish the same functionality with less effort.
Take a look into this documents:
Differences Between Calling a VI with an Invoke Node and Calling a VI with a Call by Reference Node
Asynchronously Calling a VI without Collecting the Results - LabVIEW 2016 Help - National Instruments
**The code for this example has been edited to meet the new Community Example Style Guidelines. The edited copy is marked with the text ‘NIVerified’. Read here for more information about the new Example Guidelines and Community Platform.**
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.