Colors Property

Returns or sets colors in the palette for a Chart object. The palette has 56 entries, each represented by an RGB value. Read/write Variant.

expression.Colors(Index)

expression Required. An expression that returns one of the objects in the Applies To list.

IndexOptional Variant. The color number (from 1 to 56). If this argument isn’t specified, this method returns an array that contains all 56 of the colors in the palette.

Example

This example sets color five in the color palette for the active chart.

ActiveChart.Colors(5) = RGB(255, 0, 0)