Chart Group Object and the Chart Groups Collection Example

This sets the gap width of all column groups in the chart to 10% and sets each column to have a different color:

Sub FormatColumns()

Dim oCht As Chart

Dim oCG As ChartGroup

For Each oCG In Charts(1)

.ColumnGroups

oCG.GapWidth = 10

oCG.VaryByCategories =

True

Next

End Sub

0 0

Post a comment