Page 1 of 1

TCustom3dSeries.AddXYZ help incorrect

Posted: Wed May 28, 2008 7:30 am
by 10547089
Hello,

I am trying to find out how to add a point to a TColorSeries and set the color. There is an AddXYZ in the help for TCustom3DSeries that is incorrect.

It says
The AddXYZ method adds a new point to the Surface Series.
You can also use the Surface OnGetYValue event to supply Y values for a given pair of X,Z values.
Specific colors can be assigned to each Surface polygon by using the AColor parameter.
There is no AColor parameter as far as I can tell, and the help is referring to a surface polygon.

the way that we added the colors are

Code: Select all

for i:=0 to 5 do
  for j:=0 to 5 do
  begin
    idx:=series1.addXYZ(i,0,j);
    series1.ValueColor[idx]:=clRed;
  end;
Is there a way to add a color in just on line. Since a colorgrid is basically useful for displaying a picture, I would like something like

Code: Select all

ColorGridSeries.AddXYZ(x,y,someColor)

Posted: Wed May 28, 2008 10:15 am
by narcis
Hi David,

You need to populate such series as described on this thread.

You can specify the color in the add mehtod like this:

Code: Select all

  for x:=0 to 10 do
    for  z:=0 to 5 do
      Series1.AddXYZ(x,random,z,'',clRed);
That's what the help file means.

Posted: Wed May 28, 2008 2:00 pm
by 10547089
Hi Narcis,

Thanks for the help. If you guys could update the help file to be more accurate, that would be great.