Partager via


LegendEntry Interface

Represents a legend entry in a chart legend.

Namespace:  Microsoft.Office.Interop.PowerPoint
Assembly:  Microsoft.Office.Interop.PowerPoint (in Microsoft.Office.Interop.PowerPoint.dll)

Syntax

'Declaration
<GuidAttribute("92D41A70-F07E-4CA4-AF6F-BEF486AA4E6F")> _
Public Interface LegendEntry
'Usage
Dim instance As LegendEntry
[GuidAttribute("92D41A70-F07E-4CA4-AF6F-BEF486AA4E6F")]
public interface LegendEntry

Remarks

The LegendEntry object is a member of the LegendEntries collection. The LegendEntries collection contains all the LegendEntry objects in the legend.

Each legend entry has two parts:

  • The text of the entry, which is the name of the series or trendline associated with the legend entry.

  • The entry marker, which visually links the legend entry with its associated series or trendline in the chart.

The formatting properties for the entry marker and its associated series or trendline are contained in the LegendKey object.

The text of a legend entry cannot be changed. LegendEntry objects support font formatting, and they can be deleted. No pattern formatting is supported for legend entries. The position and size of entries is fixed.

There is no direct way to return the series or trendline that corresponds to the legend entry.

After legend entries have been deleted, the only way to restore them is to remove and re-create the legend that contained them by setting the HasLegend property for the chart to false and then back to true.

See Also

Reference

LegendEntry Members

Microsoft.Office.Interop.PowerPoint Namespace