Is it possible to generate an array of cluster with the following characteristic?
1. each element cluster in the array will be of different type
2. depending on the code, each element could be a different data type at different time. For example, the cluster at array will be a string when the user input is one, and array will be a U16 if the user input is two. The index for a particular datatype is arbitary.
Let me know. I am trying to write a subvi that will get an array of U16 convert the array to an array of cluster with string, U16, double, single, U32, etc.
Solved! Go to Solution.
Yes. Use an array of variants.
You use the To variant to turn your data type into a variant to store in the array. You use Variant to Data to convert the variant back to the original datatype, you just need to specify the datatype.
That would work great. Thanks!