Example Code

Find the Datatype of a Shared Variable on Another Computer in LabVIEW

Code and Documents

Attachment

Overview:

This VI exemplifies how to determinate the data type of a network shared variable.
Description:

This operation is done by comparing the variant data with several other data types converted into variant. Currently is possible to determinate if the variable is double, I16, Extended Precision, U64, Single Precision, Fixed Point <+/-, 64, 32>, I64, I32, Complex Extended, U8, U16, I8, Boolean, String, Array U32 and Array of Doubles.
There are several data types that are still missing. It could be easily expanded to include other data types.
Requirements:
LabVIEW Base Development System.
Steps to Implement or Execute Code:
1. Open the attached VI named “Find Shared Variable Data Type LV 2012 - NI Verified.vi”.
2. Select a network shared variable from the reference input control.
3. Run the VI.
4. Read the value from the True Data Type.
Additional Information or References: 


Snippet 7457.png**This document has been updated to meet the current required format for the NI Code Exchange.**

 

 

National Instruments
RIO Embedded Hardware PSE

CompactRIO Developers Guide

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.