Joined: 02 Nov 2015
Topic: Chart FIFO
Posted: 01 Feb 2016 at 11:09am
Is there any way to have a FIFO behaviour in a LineChart? I want to delete the first point of the diagram and add another point. I tried the following:
(Chart 3 is the TChart and Std_dm is the TLineSeries. DataPoints is my "max" of desired data points in the diagram)
if Std_dm.count > DataPoints then
When I do this the following happens: http://www.dropbox.com/s/dht0tz4ycnpbob4/Charts.PNG?dl=0
It deletes with every run the first point and adds every new value at the Index "DataPoints".
A workaround is to clear the diagram and add a complete array. But this seems a little bit sloppy.
Joined: 18 May 2010
|Post Options Quote Reply Posted: 01 Feb 2016 at 1:43pm|
If you are returning your points through the virtual method GetPoint and GetNumberOfPoints, then you need to wrap the code that removes a point with BeginUpdate / EndUpdate.
|Forum Jump||Forum Permissions
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum