IndicatorColorIndex Property

Microsoft Excel Visual Basic

XlColorIndex can be one of these XlColorIndex constants.
xlColorIndexAutomatic The default system color.
xlColorIndexNone Not used with this property.

expression.IndicatorColorIndex

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

Remarks

You can specify a particular color for the indicator by entering the corresponding index value. You can use the Colors property to return the current color palette.

The following illustration shows the color-index values in the default color palette.

Color index values in default color palette

Example

In the following example, Microsoft Excel checks to see if the indicator color for error checking is set to the default system color and notifies the user accordingly.

Sub CheckIndexColor()

    If Application.ErrorCheckingOptions.IndicatorColorIndex = xlColorIndexAutomatic Then
        MsgBox "Your indicator color for error checking is set to the default system color."
    Else
        MsgBox "Your indicator color for error checking is not set to the default system color."
    End If

End Sub