Differences Between the Bundle and Bundle By Name Functions

Problem:What is the difference between the Bundle and Bundle By Name VIs?

Solution:The Bundle VI is used to assemble a cluster from individual elements or replace elements in an existing cluster. The Bundle function refers to cluster elements by their position in the cluster. For this reason, using the Bundle function to replace existing cluster elements requires that the number of input terminals must match the number of elements in the input cluster and that you know the order of elements in that cluster.

The Bundle By Name function is also used to replace one or more elements in an existing cluster. However, it cannot be used to assemble a cluster. This function refers to cluster elements by name instead of by their position in the cluster. As a result, this function can only access cluster elements that have their own label attached to them. Additionally, the number of input terminals does not need to match the number or order of elements in the input cluster. The Bundle by Name function is useful when working with data structures that may change during the development process because rewiring/resizing the cluster is unnecessary when a new component is added or the cluster is modified.

In LabVIEW 7.1 or earlier, refer to the LabVIEW User Manual for more information about these and other cluster functions. In LabVIEW 8.0 or later, refer to the Cluster & Variant Functions topic inthe LabVIEW Help.