LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to pass a graph to another vi without stripping off the properties????

Would it be too hard to do this?
LV 8.6 on Windoze XP
0 Kudos
Message 1 of 21
(3,926 Views)
What do you mean by "pass a graph". Are you referring to the data or to the actual graph indicator? For the latter you need to pass a control reference.
Message 2 of 21
(3,916 Views)

... and for the data, you would just wire... the data (array). 🙂

Both are relatively simple.

What smercurio proposes would retain (most?/all?) the properties of the graph.  Are you using cursor lines, etc?



Message Edited by JoeLabView on 03-12-2008 05:20 PM
Message 3 of 21
(3,912 Views)
I want to be able to have a vi (MYxyGraph.vi) that takes data and all of the other information that makes an xy graph meaningful and produces a graph indicator that incorporates all of that data (metadata IS data -- legends, colors,titles,patterns, etc...).  I would like to for that indicator to get returned as an output argument of MYxyGraph.vi.

What do I have to do that will get me close to this use case?

Thanks


Message Edited by Clueless1 on 03-12-2008 04:27 PM

Message Edited by Clueless1 on 03-12-2008 04:28 PM
LV 8.6 on Windoze XP
0 Kudos
Message 4 of 21
(3,910 Views)
Like I said, a control reference as an output would give you this. However, my guess is that you want to apply this to a higher level VI that has a graph, and are assuming that you can just copy the graph onto this graph in a higher level VI. If this is the case what you actually should do is to create a VI that has a graph control reference as an input. You pass it the control reference of the graph in your higher level VI, and let the subVI set all the properties programmatically.
Message 5 of 21
(3,904 Views)
OK, I think i get it. 

Thanks
LV 8.6 on Windoze XP
0 Kudos
Message 6 of 21
(3,903 Views)

Additionally to what Mr. smercurio stated, you can wire the reference from the original graph to property nodes in the sub-vi to "extract" the property information.

The property node from the "Application Controls" of the Functions palette.

Message 7 of 21
(3,898 Views)
I guess it's like having to malloc a struct before writing  data to it.   All front panel objects must be allocated in the vi that owns the front panel and they only exist in that panel.  Objects that are "passed" as indicators(outputs) of the parent into the control (input) of the subvi(child)  are  not pointers but cause a memcopy into a new instance of the object.  Yes/No?????
LV 8.6 on Windoze XP
Message 8 of 21
(3,896 Views)

are you referring to the reference & property node?  I tend to think more as objects...  or in the ms world... active-x objects...

Remember that objects can have methods and properties. Where properties are the attributes of an object (size, color, value, visibility, etc).

Message 9 of 21
(3,889 Views)
I'm using the term object here more in the generic sense of something (cluster,variable,array,waveformGraph, etc ...) that, once instantiated, occupies a chunk of memory (either stack or heap I don't know)  until it is released either explicitly, or by the underlying architecture of labview.  I'm just trying to get a peek behind the curtain in order to better understand how LV wants me to program (wire?) it.
LV 8.6 on Windoze XP
Message 10 of 21
(3,886 Views)