ColumnCount Property [AutoLegend]

The ColumnCount property returns or sets the number of columns in the legend. Returns a Long.

Syntax

object.ColumnCount

object.ColumnCount =ColumnCount

 

Parameter Type Description
ColumnCount Long required, sets number of columns in the legend

 

Example 1

The following example demonstrates how to set the number of legend columns to three.

'Set the number of columns for a legend to 3
Legend.ColumnCount = 3

Example 2

This example demonstrates how to return the number of columns in the legend

Debug.Print Legend.ColumnCount

 

Used by: AutoLegend Object