LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I get Graph value to an array?

Hi,

I m new to this Forum.

I m making a data logger and the data's are plotted in a Graph.The graph would have 100thousand point and would have around 64 different plots.For offline analysis, I store the entire panel using SavePanelSate().This methode I use to store like a database.

And then once I recall the panel suing RecallPanelState(), I would like to Zoom, Scroll,Hide, Change the line type and Change the color of plots.

I can achive Zoom, Scroll but unable to Hide or change the color plot when the Graph is already plotted.

My question here is:

1) Can get the Graph plots to arrays ? so that I can replot..

2) If not then Is ther any way to change the plot colors or Hide, UnHide once plotted..

 

Hope I get some tricks here...

Thanx

Bala

0 Kudos
Message 1 of 3
(3,285 Views)

Hi Bala,

 

certainly you get some assistance here Smiley Wink

You also should have a look at the examples provided with CVI. For example, graphs.cws shows how to change the color of a plot...

 

In general, the function SetPlotAttribute (, , , ATTR_TRACE_COLOR, ); SetPlotAttribute (, , , ATTR_PLOT_STYLE, );, etc. will be useful for such purpose.

What is important is to have the 'Data mode' set to 'retain' and the 'Copy original plot data' checked.

0 Kudos
Message 2 of 3
(3,282 Views)

In case you want to retrieve plot data, you can use GetPlotAttribute function with the attributes 

ATTR_PLOT_XDATA, ATTR_PLOT_XDATA_TYPE and ATTR_PLOT_XDATA_SIZE for the X axis and ATTR_PLOT_YDATA, ATTR_PLOT_YDATA_TYPE and ATTR_PLOT_YDATA_SIZE for the Y axis.

 

All Set/GetPlotAttribute functions neet for you to supply the plot handle, which you may need to store somewhere to retain the correct association between data/plots and actual trend recorded.

 



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 3 of 3
(3,272 Views)