martinctc
6/14/2017 - 8:41 AM

Tweak Data Labels of PowerPoint Charts

Tweak Data Labels of PowerPoint Charts

Sub TweakDataLabelsPPTChart()

'--------------------------------------------------
' Changes Data Labels at a click for PPT
' At the moment works best for a simple bar chart
' More flexible variations of this macro to follow
'--------------------------------------------------
Dim i, j As Long
Dim shp1 As Shape

Set shp1 = ActiveWindow.Selection.ShapeRange(1)
i = 1
j = shp1.Chart.FullSeriesCollection.Count
Debug.Print j

For i = 1 To j
    shp1.Chart.FullSeriesCollection(i).DataLabels.Font.Color = RGB(75, 190, 170) 'Change required colour here
    shp1.Chart.FullSeriesCollection(i).DataLabels.Position = xlLabelPositionOutsideEnd 'Change required label position here
Next

End Sub