LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Naming an initialized array

I am creating 6 arrays with Initialize Array at the very beginning of a program in order to not loser performance later on.
 
I would like to name these arrays and bundle them into a cluster for tidy wiring... How should I go about this?
 
I've thought about creating indicators for all the arrays and then property nodes for all the indicators and then bundling the outputs of the property nodes but I am hoping there is a better way (if that would even work)
 
Thanks,
 
Dave
0 Kudos
Message 1 of 7
(3,585 Views)

When you build the cluster, you just have to provide a constant with the names to the 'cluster' input of the bundle function. You can provide the same input to a bundle by name.

Message Edited by Dennis Knutson on 11-22-2006 02:24 PM

Message 2 of 7
(3,575 Views)
Yeah, there's definitely an easier way. Use the Bundle by Name function in the Cluster palette, and wire up a dummy cluster of named arrays to the top input as seen below:

Message Edited by Jarrod S. on 11-22-2006 03:24 PM


Beat by DK again! 🙂

Message Edited by Jarrod S. on 11-22-2006 03:25 PM

Jarrod S.
National Instruments
0 Kudos
Message 3 of 7
(3,576 Views)
Hi Dave,

there are several options.
How do you initialize?
If you use a BD constant just change the label of that constant
If you build an array maybe the label of the element helps you

Otherwise you could typecast the array where the type is an array constant of 0-elements where the constant has a name, this will name the 'wire' and thus the cluster input!

Ton


edit: Beaten twice

Message Edited by TonP on 11-22-2006 10:30 PM

Free Code Capture Tool! Version 2.1.3 with comments, web-upload, back-save and snippets!
Nederlandse LabVIEW user groep www.lvug.nl
My LabVIEW Ideas

LabVIEW, programming like it should be!
0 Kudos
Message 4 of 7
(3,566 Views)
hi

initilizing arrays is always a good idea, but keep in mind that using the property nodes is gone eat off your performance.

so what about this way:
0 Kudos
Message 5 of 7
(3,558 Views)

Cool new idea...

 

viScience_0-1738438796218.png

 

0 Kudos
Message 6 of 7
(107 Views)

The issue was setting a name on an unnamed array, you're sending in a named array ... Try it without the Cell States label ... 

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 7 of 7
(74 Views)