I insert several series (TSurfaceSeries) in the Chart1(TChart of Delphi 7.0, TeeChart7.07), when I input the code as:
chart1.series[0].addxyz(0,1,0);
chart1.series[1].addxyz(0,2,0);
the data cann’t be accepted ,and the error notice is “ undeclared identifier: ‘addxyz’ ” .
the data can be accepted with follow code :
series1.addxyz(0,1,0);
series2.addxyz(0,2,0);
But if I want to do a cycle for all of the series, should I do it one by one? Thank you!
A Question About Data Insert in Series
Hi.
tChart.Series is defined as TChartSeries and it doesn't introduce AddXYZ method. To make it work, you'll have to typecast TChartSeries to TSurfaceSeries (of course, if possible). Something like this:
tChart.Series is defined as TChartSeries and it doesn't introduce AddXYZ method. To make it work, you'll have to typecast TChartSeries to TSurfaceSeries (of course, if possible). Something like this:
Code: Select all
if (tChart.Series[0] is TSurfaceSeries) then
with (tChart.Series[0] as TSurfaceSeries) do
begin
AddXYZ(...);
end;
Marjan Slatinek,
http://www.steema.com
http://www.steema.com