CollapseLegendItems: Boolean;
The CollapseLegendItems property determines parameters of displaying legend of a secondary pie chart.
If the property is set to True, the legend displays an icon, name of the combined group of series and names of all series of the main chart. If the property is set to False, the legend displays icons and names of all chart series. The default property value is False.
This example requires a regular report sheet with a chart on it.
Sub My;
Var
C: IChart;
CircleEx: IChartCircleExInfo;
Begin
C := (PrxReport.ActiveReport.ActiveSheet.Table.Objects.Item(0).Extension As IChart);
C.Type := ChartType.SecondaryBars;
CircleEx := C.CircleInfoEx;
C.DisplayLegend := True;
CircleEx.CollapseLegendItems := True;
PrxReport.ActiveReport.ActiveSheet.Recalc;
End Sub My;
Executing this example displays a legend with icons, names of the combined series group and all series of the main chart.
See below examples of charts and legends with icons and names for all chart series (left) and names of the combined group of series and all series of the main chart (right):
See also: