I decided that it was cool to have nested clusters. For example, all the analog data I read in my control application is in a single cluster, which is composed of categorical clusters (ie "pressure", "temperature", etc). Now it is time to log data to a .tdms file, and it sure would be convenient to generate a pair of arrays from that 'root' cluster containing the labels of all the numeric controls and their data.
I found this thread, http://forums.ni.com/t5/LabVIEW/Is-there-a-quot-Get-Cluster-Names-quot-VI/td-p/666555, which uses a property node to retrieve the labels of the controls in the root cluster. This is great, but I only get the labels of the nested clusters (and none of their elements).
My lab-fu isn't strong enough to figure out an elegant solution to this. I can brute force it by unbundling and making indicators, then using the property note separately on them... but I suspect there must be a better way!
The attached VI is my best effort at solving this. It works, but I'm concerned that it's not the best code for the following reasons:
1. Am I really allowed to point to front panel items when this subvi will be deployed to RT as part of a startup executable?
2. If the subvi is within a loop, what do I do instead of 'build array' to avoid memory use issues? All the NI examples use this and I've read so much about how I shouldn't.... what is the functional alternative?
Many thanks for your time!