P positrom2 Active Member Licensed User Longtime User Feb 6, 2014 #1 I have added a series of points to a Scatterchart using Adddata: Code: Copy For j=3 To steps-2 AddData(GetdataMaxr, j*stepp, maxr_array(j,0)) Next Usually, I remove that series prior to adding a new series of points to avoid filling up the memory space: Code: Copy GetdataMaxr.RunMethod("remove",Array As Object(SeriesJO)) Occasionally, however, I wish to keep a series of plotted points to compare with a previous series. This I do by once omitting the "remove" method. That preserves a previous plotted series and a new series of plotted additionally. However, when the screen has been messed up by repeatedly omitting the "remove" method, how to clear the Chart, i.e. remove also the "old" data points?
I have added a series of points to a Scatterchart using Adddata: Code: Copy For j=3 To steps-2 AddData(GetdataMaxr, j*stepp, maxr_array(j,0)) Next Usually, I remove that series prior to adding a new series of points to avoid filling up the memory space: Code: Copy GetdataMaxr.RunMethod("remove",Array As Object(SeriesJO)) Occasionally, however, I wish to keep a series of plotted points to compare with a previous series. This I do by once omitting the "remove" method. That preserves a previous plotted series and a new series of plotted additionally. However, when the screen has been messed up by repeatedly omitting the "remove" method, how to clear the Chart, i.e. remove also the "old" data points?
P positrom2 Active Member Licensed User Longtime User Feb 6, 2014 #2 I found this https://community.oracle.com/thread/2448582?tstart=0 lineChart.getData().clear(); will remove all the series from the chart. Click to expand... but how to implement it? Upvote 0
I found this https://community.oracle.com/thread/2448582?tstart=0 lineChart.getData().clear(); will remove all the series from the chart. Click to expand... but how to implement it?
stevel05 Expert Licensed User Longtime User Feb 6, 2014 #3 Are you running from the examples from the forum? In which case it would be similar to adding the data series: Code: Copy 'Assuming Linechart and LCGetData are JavaObjects LCGetData=LineChart.RunMethod("getData",Null) LCGetData.RunMethod("clear",Null) If this isn't the case, please zip and post your code. Upvote 0
Are you running from the examples from the forum? In which case it would be similar to adding the data series: Code: Copy 'Assuming Linechart and LCGetData are JavaObjects LCGetData=LineChart.RunMethod("getData",Null) LCGetData.RunMethod("clear",Null) If this isn't the case, please zip and post your code.
P positrom2 Active Member Licensed User Longtime User Feb 6, 2014 #4 Thanks stevel05, the "Null" I never will learn. It works. Upvote 0