Page 1 of 1
Used Series is not stored for tools?
Posted: Wed Jun 04, 2008 4:59 am
by 9349911
Hi !
Some of our customers use a TSeriesRegionTool for displaying the region above the curve in a different color / gradient. If they save the file und load it back the TSeriesRegionTool is gone.
It has no assigned Series. This is the export to native data ...
Code: Select all
object ChartTool1: TSeriesRegionTool
Gradient.EndColor = clWhite
Gradient.StartColor = clBlue
Gradient.Visible = True
Brush.BackColor = clWhite
end
Why don´t you save the series with the tools? Is there any way to store the used series, too?
Posted: Wed Jun 04, 2008 9:19 am
by yeray
Hi Dominik,
Could you try the following simple test? This works fine for me using latest internal steema sources.
Note that, at design time, I've added two charts and an ImportChart component. Finally, I've added a line series and a series region tool to the chart1.
Code: Select all
uses TeeStore;
procedure TForm1.FormCreate(Sender: TObject);
begin
//Chart1.View3D := False;
with ChartTool1 do
begin
Gradient.EndColor := clWhite;
Gradient.StartColor := clBlue;
Gradient.Visible := True;
Brush.BackColor := clWhite;
Series := Series1;
end;
ImportChart1.Chart := Chart2;
SaveChartToFile(Chart1,'C:\tmp\test.tee',true);
ImportChart1.LoadFromFile('C:\tmp\test.tee');
end;
Posted: Thu Jun 05, 2008 6:09 am
by 9349911
Hi Yeray,
I did some further tests and figure out the problem.
The series isn´t stored if you have dynamically generated Series.
Try the following:
- Add a chart to a form.
- Add a Region Tool to that chart
- Add a TFastLineSeries to the Chart and use this code:
Code: Select all
Chart2[0].FillSampleValues(100);
ChartTool2.Series := Chart2[0];
SaveChartToFile(Chart2, 'c:\test.tee', True, True);
The result will this:
Code: Select all
object ChartTool2: TSeriesRegionTool
Brush.BackColor = clWhite
Series = Series2
end
As you can see ... The series is added correctly.
Now delete the series from the chart and run this code:
Code: Select all
Chart2.AddSeries(TFastLineSeries);
Chart2[0].FillSampleValues(100);
ChartTool2.Series := Chart2[0];
SaveChartToFile(Chart2, 'c:\test.tee', True, True);
You will get this:
Code: Select all
object ChartTool2: TSeriesRegionTool
Brush.BackColor = clWhite
end
So what can I do to get the series stored in the Tee file (or the stream)?
Posted: Thu Jun 05, 2008 8:36 am
by yeray
Hi Dominik,
You are right. It seems that Region series link is not saved in the tee file when the series is added to the chart at runtime.
I've added it to the wish list to be fixed in future releases (TV52013106). And I'm afraid I can't think on any satisfying workaround for this by the moment.
Posted: Thu Jun 05, 2008 8:42 am
by 9349911
Well well well ....
That are not really good news.
And it wont be possible to have that fix within the 8.03 release?
Posted: Thu Jun 05, 2008 8:57 am
by yeray
Hi Dominik,
I'm afraid development of v8.03 has already been closed. We are currently testing the installers and fixing any issue they may have to make the version public ASAP.