IsIndex Property

Read-only. Returns a Boolean value. If the object has an indexed color, returns TRUE. Otherwise returns FALSE.

Applies to objects: Color

Syntax

[Let] RetVal = object.IsIndex

The IsIndex property syntax has these parts:

Part Description
object A reference to an instance of the object.
RetVal A Boolean type variable.

Remarks

It's recommended that you check the status of this property before using the Index Property.

Example

This example checks whether the fill color in a Shape object is an indexed color. If yes, it displays the index of the color.

dim s as shape

' Create a Shape object
s = thisDoc.ActivePage.DrawRect(100,100,1000,1000)
If s.FillColor.IsIndex <> false Then ' An indexed color?? trace s.FillColor.Index ' If yes, display the index endif

 

See Also

Color Object, Index Property, IsRGB Property, IsCMYK Property