ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Passing parameters to VIs

Using LV 6.1 with WIN 2000. I am wanting a way to pass several graph parameters to a SubVI without having to cluster properties together. I have several graphs that I need to pass serveral parameters each and would like a compact way to pass all parameters for an XY graph into a SubVI. Are references the way to go here? if so, does anyone have example code on this?
0 Kudos
Message 1 of 4
(2,970 Views)
I think references should be good for you. If you pass a reference then all the properties will be available in the subVI.

Watch the VI attached !

Julien
0 Kudos
Message 2 of 4
(2,970 Views)
> Using LV 6.1 with WIN 2000. I am wanting a way to pass several graph
> parameters to a SubVI without having to cluster properties together.
> I have several graphs that I need to pass serveral parameters each and
> would like a compact way to pass all parameters for an XY graph into a
> SubVI. Are references the way to go here? if so, does anyone have
> example code on this?

References are really a way to interact with UI object, not a general
pointer to data. In LV, which is a value-based dataflow language, you
either pass the parameters individually, in an array if they are of the
same type, or in a cluster if they are not.

Greg McKaskle
0 Kudos
Message 3 of 4
(2,970 Views)
If I'm not mistaken, all data operations done on references must be done in the UI thread. Depending on what thread the sub-vi is normally running in, this can have severe performance issues.

Have a look here for more information.

Shane.
Using LV 6.1 and 8.2.1 on W2k (SP4) and WXP (SP2)
0 Kudos
Message 4 of 4
(2,970 Views)