1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46
| Sub Etiquettes_Serie()
Application.ScreenUpdating = False
Dim reihe As Integer 'pour serie
Dim indD As Integer ' indice du nom du diagramme
reihe = 2
indD = 1
'
For indD = 1 To ActiveSheet.ChartObjects.Count
ActiveSheet.ChartObjects("Diagramm " & indD).Activate
'ActiveChart.PlotArea.Select
ActiveChart.ApplyDataLabels
'ActiveChart.SeriesCollection(3).DataLabels.Select
' Selection.ShowSeriesName = True
' Selection.ShowValue = False
ActiveChart.SeriesCollection(1).DataLabels.Select
Selection.ShowSeriesName = False
Selection.ShowValue = False
For reihe = 2 To 226
'
ActiveChart.SeriesCollection(reihe).DataLabels.Select
If ActiveChart.SeriesCollection(reihe).Value = 0 Then
Selection.ShowSeriesName = False
Else: Selection.ShowSeriesName = True
End If
Selection.ShowValue = False
' Selection.Separator = " "
With Selection.Format.TextFrame2.TextRange.Font.Fill
.Visible = msoTrue
.ForeColor.ObjectThemeColor = msoThemeColorBackground1
.ForeColor.TintAndShade = 0
.ForeColor.Brightness = -0.150000006
.Transparency = 0
.Solid
.Bold = msoTrue ' Selection.Format.TextFrame2.TextRange.Font.Bold
End With
Next reihe
Next indD
End Sub |
Partager