Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

Get waveform graph on screen data

I am using the Waveform Graph control, along with multiple waveform plots.

 

However, if the user zooms in and I call WaveformPlot.GetYData(), it returns the entire data array, not just the points shown on the graph.

 

Is there any easy way to access only the visible data (i.e. trim the array so it contains only the points that are visible on the graph)?

0 Kudos
Message 1 of 2
(3,439 Views)

Shansen,

 

When you are zoomed in you can use the properties of the graph to get the hight and low limits. Then you can retrieve the entire array from GetYData and use the limits to truncate the array. Alternatively you can truncate the array before calling GetYData, but then you wouldn't be able to zoom-out.

 

2009-10-30_111844.jpg

Richard S -- National Instruments -- (former) Applications Engineer -- Data Acquisition with TestStand
0 Kudos
Message 2 of 2
(3,404 Views)