Page 1 of 1

Creat LineSeries with ColorGridSeries Y Values?

Posted: Fri Feb 18, 2005 10:00 am
by 8441848
Hi,

I have a TColorGridSeries (named Series10 - affected with ChartTool5) and a TLineSeries(named Series1). I would like use the X and Z value to draw the LineSeries.

Is it possible to do somthing like this(?):

Code: Select all

For i:= 1 to 10 do
  Series1.AddXY(Series10.GetXZValue(ChartTool5.XValue, i), i);
Unfortunaty this not work: all Values are null. In helpfiles I find that GetXZValue returns zero if OnGetYValue is not assigned. What OnGetYValue need to be assigned on: I don't find.

Thank's for your help...

Cyril

Posted: Mon Feb 21, 2005 3:02 pm
by Pep
Hi Cyril,

the GetXZValue does not return value for specific index. This event can be used only for constructing the surface from formula. i.e. you have to specify y=y(x,z) -> in this case the GetXZValue will return y for specific x and z.
If you simply populate series with data (not by specifying a function) the GetXZValue will not work i.e. it will always return 0 (or -1?).
There is an example of this method in the Demo Features project under the "All Features -> Chart styles -> Extended ", the "Surface" (first) example. To get the YValues of the ColorGrid Series you can use :
TColorGridSeries.Value[x,z]

Posted: Wed Feb 23, 2005 12:40 pm
by 8441848
Hi!
:D - Thank's a lot your your answer! It will help me a lot.

Cyril