Legend Object

Description

Represents the legend in the specified chart. Each chart can have only one legend. The Legend object contains one or more LegendEntry objects; each LegendEntry object contains a LegendKey object.

Using the Legend Object

Use the Legend property to return the Legend object. The following example sets the font style for the legend to bold.

myChart.Legend.Font.Bold = True
Remarks

The chart legend isn't visible unless the HasLegend property is True. If this property is False, properties and methods of the Legend object will fail.

Properties

Application property, AutoScaleFont property, Border property, Creator property, Fill property, Font property, Height property, Interior property, Left property, Name property, Parent property, Position property, Shadow property, Top property, Width property.

Methods

Clear method, Delete method, LegendEntries method.