LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Building clusters

Is there any method to programatically build a cluster one field at a time,
like adding an element to an array??
Randall Miller
0 Kudos
Message 1 of 3
(2,656 Views)
I don't know exactly what you mean, but if you can do it
with arrays you could use them and next convert the array
to cluster using "Array to Cluster" in the cluster Function
palette.
Hope this helps, if not, send more detailed information to
try solving your problem.

Gorka


* Sent from AltaVista http://www.altavista.com Where you can also find related Web Pages, Images, Audios, Videos, News, and Shopping. Smart is Beautiful
0 Kudos
Message 2 of 3
(2,656 Views)
I have to read/write a large cluster of data to an ini file. I did not want to
hard code 100+ fields. I was looking to develop a table driven approach.

The cluster can be built by creating a table (constant) of the section, key,
ini file data type, and cluster data type. An engine vi can step through this
table and read each field, convert it to flattened data, and append the flat
string and data type to separate lists. The final step is to unflatten the data
with the type string that has been built.

The larger problem is writing the ini file. The cluster must be flattened and
the type data used to break it appart and write to the ini file keys using the
same constant table (that was used to read the data).
If the cluster labels could be accessed at comp
ile time, then it might be
possible to completely automate the process be building the required control
tables for the clusters.

Randall Miller
0 Kudos
Message 3 of 3
(2,656 Views)