LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
manu.NET

Adaptive "Bundle by name" from the cluster output, if no input type is wired ....

Status: New

Hello,

 

When you want to "bundle by name" a cluster, you have to connect a cluster input, in order to get all the field available.

This is interresting when you want to modify only some of the elements of a existing cluster.

 

But when you want to initialize a cluster ... you must connect a cluster constant to the "bundle by name"  only to get access to the cluster elements.

 

It should be nice to have the ability to use a "bundle by name" which could adapt itself from it's output ... when no input type is wired.

 

Manu.

Manu.net
4 Comments
X.
Trusted Enthusiast
Trusted Enthusiast

The functionality you are requesting is not difficult to obtain:

 

- use a simple bundle function when first wiring your diagram

- when you are done, select the input cluster terminal and create a constant

- edit the constant's labels

- replace the "Bundle" function by a "Bundle By Name" function.

 

What you are asking for would not work if LV had no way to give a name to one or more of the inputs (or you would end up in one of those cases where one or more of the elements' names are empty and thus inaccessible using "Unbundle By Name").

AristosQueue (NI)
NI Employee (retired)

It would be possible to do this, but LV generally shies away from propagating type info upstream -- it is a bit counter intuitive, IMHO. I know we do this currently somewhere because I've seen a function in the editor to do it, but I don't know what node actually uses that trick. If someone knows where that is, perhaps we could ask how people like that case and see if that suggests people would be comfortable with this case.

johnsold
Knight of NI

AQ,

 

Is not creating a control (not indicator) from a wire the same process of propagating type info upstream?

 

I have occasionally thought that the idea proposed here would be useful.  Now that cluster constants can be resized or put into subVIs with miniature icons, it does not bother me as much as formerly.

 

I am giving it a kudo, to encourage thinking about whether it is appropriate or exactly how it might work.

 

Lynn

crossrulz
Knight of NI

AQ - "I've seen a function in the editor to do it, but I don't know what node actually uses that trick."

Variant to Data does this

variant to data.PNG


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5