ICustom3DPaletteSeries.AddPalette
ICustom3DPaletteSeries

function AddPalette(Value: Double; Color: OLE_COLOR): Integer;

Type Library
TeeChartx

Description
This method adds a new color Palette entry to the end of Palette list. Add returns the position of the entry in the Palette list. The Color parameter will be used to fill polygons with Y values up to the Value parameter. Custom color palettes can be created using this method. The UsePalette property should be True to use the palette entries.

Example [Visual Basic]:

This code creates a customized color palette. Polygons with Y values lower than or equal to 3000 will be filled in Green color, Polygons with Y values lower than or equal to 2000 will be filled in Yellow color and Polygons with Y values lower than or equal to 1000 will be filled in Red color.

With TChart1

.Series(0).asSurface.ClearPalette

.Series(0).asSurface.AddPalette 1000, vbRed

.Series(0).asSurface.AddPalette 2000, vbYellow

.Series(0).asSurface.AddPalette 3000, vbGreen

.Repaint

End With