API Documentation > CorelDRAW > 2025-v26 > Palette > IVGPalette
Palette.Colors method
Gets a collection of colors in a palette
Syntax:
Function Colors() As Colors
Remarks:
The Colors property returns the collection of all colors in a palette.
Examples:
The following VBA example displays the name of the default color palette and the number of colors it contains.
Sub Test()
Dim pal As Palette
Set pal = ActivePalette
MsgBox "Default palette '" & pal.Name & "' contains " & pal.Colors.Count & " color(s)" 
End Sub Sub Test()
Dim s As Shape
Set s = ActiveLayer.CreateEllipse2(2, 2, 1)
s.Fill.ApplyUniformFill ActivePalette.Colors(15) 
End Sub