LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Reset chart history using chart reference

Solved!
Go to solution

I want to clear all the data from a chart using its reference, but this property is unavailable. So far the only way to do this seems to be by using a static property node (the one you create by right clicking the chart and selecting the desired property). Is there any other way?

 

0 Kudos
Message 1 of 9
(3,563 Views)

You must be doing something wrong. The chart history is available if you use a reference for the property node.

 

Can you attach a simplified version of your code that shows the problem?

 

 

Message Edited by altenbach on 01-11-2009 03:49 PM
0 Kudos
Message 2 of 9
(3,562 Views)
I have attached part of the vi showing that it's missing from the list. Maybe it's because I'm using reference conversion?
0 Kudos
Message 3 of 9
(3,552 Views)

Can you attach a simplified version of the VI instead? I cannot debug an image. 😉

0 Kudos
Message 4 of 9
(3,541 Views)

Sorry, I have attached a simple vi. Try changing the property "Update Mode" to "History Data".

 

0 Kudos
Message 5 of 9
(3,535 Views)
Solution
Accepted by topic author abdel2

Because the property node is not strictly typed, the chart history is not available.  If you make the Waveform Chart reference from the chart waveform, the output of the "To more specific class" will be strictly typed.

See attached.

0 Kudos
Message 6 of 9
(3,533 Views)
Ya I guess I'll just have to create a hidden chart and use its reference. Thanks.
0 Kudos
Message 7 of 9
(3,523 Views)

abdel2 wrote:
Ya I guess I'll just have to create a hidden chart and use its reference. Thanks.

Exactly what are you trying to do?  Is this code supposed to be part of some subVI?  It doesn't make sense to make a hidden chart so that you can have a reference to it.  If you are making a subVI that acts on whatever reference is passed to it, usually their is a way to make a control or indicator of the reference in the main VI, and copy it to the subVI.  It can be tricky in working with these types of references as sometimes a reference may suddenly become non-strict and you don't know why the action you took did that.

 

If you can give more explanation on the bigger picture of what you are doing, I'm sure there is a way to do it and I'm sure the users of the forum who are more expert than me such as Altenbach will know.

0 Kudos
Message 8 of 9
(3,520 Views)

I am trying to initialize the chart's properties in another vi from my current vi (where the code resides). First reason why I'm doing this is because all the new property values are in the current vi and it would be too much hassle trying to transfer them to the vi containing the chart. Second reason is that I want to dynamically change the number of plots on the chart and I can't do this while the vi is running.

 

I guess I could also leave everything as it is but simply clear the chart history when the other vi runs. Hopefully I won't see any flickers.

0 Kudos
Message 9 of 9
(3,516 Views)