Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 30 additions & 1 deletion File-Formats/Presentation/Charts/Chart-Data-Labels.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ control: PowerPoint
documentation: UG
---

# Chart Data Labels
# Chart Data Labels in PowerPoint

Data Labels on a chart make it easier to understand. They show important information about the lines or points on the chart. Using Presentation, you can **customize the data labels in the chart**.

Expand Down Expand Up @@ -247,6 +247,35 @@ chart.Series(0).DataPoints(0).DataLabels.Layout.ManualLayout.Top = 3
{% endhighlight %}
{% endtabs %}

## Show Leader lines

The leader lines can be shown in a chart through [ShowLeaderLines](https://help.syncfusion.com/cr/file-formats/Syncfusion.XlsIO.Implementation.Charts.ChartDataLabelsImpl.html#Syncfusion_XlsIO_Implementation_Charts_ChartDataLabelsImpl_ShowLeaderLines) API which can be set to all data labels by enabling the leader lines for [DefaultDataPoint](https://help.syncfusion.com/cr/file-formats/Syncfusion.XlsIO.Implementation.Charts.ChartDataPointsCollection.html#Syncfusion_XlsIO_Implementation_Charts_ChartDataPointsCollection_DefaultDataPoint).

The following code illustrates how to enable the leader lines for all data labels in the chart.

{% tabs %}
{% highlight c# tabtitle="C# [Cross-platform]" %}

// Enable the leader lines in Chart.
chart.Series[0].DataPoints.DefaultDataPoint.DataLabels.ShowLeaderLines = true;

{% endhighlight %}
{% highlight c# tabtitle="C# [Windows-specific]" %}

// Enable the leader lines in Chart.
chart.Series[0].DataPoints.DefaultDataPoint.DataLabels.ShowLeaderLines = true;

{% endhighlight %}
{% highlight vb.net tabtitle="VB.NET [Windows-specific]" %}

' Enable the leader lines in Chart.
chart.Series[0].DataPoints.DefaultDataPoint.DataLabels.ShowLeaderLines = true;

{% endhighlight %}
{% endtabs %}

You can download a complete working sample from [GitHub](https://github.com/SyncfusionExamples/PowerPoint-Examples/tree/master/Charts/Show-Leader-Lines/.NET).

## See Also

* [How to change text of data labels for Chart in Presentation](https://support.syncfusion.com/kb/article/13828/how-to-change-the-text-in-data-labels-inside-a-chart-in-presentation-using-c-in-aspnet-core)