I am struggling to control the font size! Below, the Chart Title ended up with size 19.75 and legend font as size 11.75. Why?
Sub MakeDoubleBars(endrow As Integer)
Dim DCht As Chart
Set DCht = Charts.Add
Set DCht = DCht.Location(Where:=xlLocationAsObject, Name:="D Chart")
With DCht
.ChartType = xl3DColumnClustered
.SetSourceData Source:=Sheets("D Chart").Range("B1:B" & endrow & ",C1:C" & endrow & ",E1:E" & endrow), PlotBy:=xlColumns
With .Parent
.Top = Range("F1").Top
.Left = Range("F1").Left
.Width = Range("F1
25").Width
.Height = Range("F1
25").Height
End With
.Rotation = 20
.RightAngleAxes = True
.AutoScaling = True
.HasLegend = True
.Legend.Position = xlLegendPositionBottom
.Legend.Font.Size = 6
.HasDataTable = False
.HasTitle = True
.ChartTitle.Characters.Text = "Annual Revenue Budget"
.ChartTitle.Font.Size = 10
.ChartTitle.Font.Underline = xlUnderlineStyleSingle
.Axes(xlValue).TickLabels.AutoScaleFont = False
.Axes(xlValue).TickLabels.Font.Size = 6
.Axes(xlValue).TickLabels.NumberFormat = "$#,##0_);[Red]($#,##0)"
.Axes(xlCategory).TickLabelPosition = xlLow
.Axes(xlCategory).TickLabels.Orientation = xlHorizontal
.Axes(xlCategory).TickLabelSpacing = 1
.Axes(xlCategory).TickLabels.AutoScaleFont = False
.Axes(xlCategory).TickLabels.Font.Size = 6
.SeriesCollection(1).Interior.ColorIndex = 36 'Yellow
.SeriesCollection(2).Interior.ColorIndex = 10 'Green
End With
End Sub
![[neutral] [neutral] [neutral]](/data/assets/smilies/neutral.gif)
Sub MakeDoubleBars(endrow As Integer)
Dim DCht As Chart
Set DCht = Charts.Add
Set DCht = DCht.Location(Where:=xlLocationAsObject, Name:="D Chart")
With DCht
.ChartType = xl3DColumnClustered
.SetSourceData Source:=Sheets("D Chart").Range("B1:B" & endrow & ",C1:C" & endrow & ",E1:E" & endrow), PlotBy:=xlColumns
With .Parent
.Top = Range("F1").Top
.Left = Range("F1").Left
.Width = Range("F1
.Height = Range("F1
End With
.Rotation = 20
.RightAngleAxes = True
.AutoScaling = True
.HasLegend = True
.Legend.Position = xlLegendPositionBottom
.Legend.Font.Size = 6
.HasDataTable = False
.HasTitle = True
.ChartTitle.Characters.Text = "Annual Revenue Budget"
.ChartTitle.Font.Size = 10
.ChartTitle.Font.Underline = xlUnderlineStyleSingle
.Axes(xlValue).TickLabels.AutoScaleFont = False
.Axes(xlValue).TickLabels.Font.Size = 6
.Axes(xlValue).TickLabels.NumberFormat = "$#,##0_);[Red]($#,##0)"
.Axes(xlCategory).TickLabelPosition = xlLow
.Axes(xlCategory).TickLabels.Orientation = xlHorizontal
.Axes(xlCategory).TickLabelSpacing = 1
.Axes(xlCategory).TickLabels.AutoScaleFont = False
.Axes(xlCategory).TickLabels.Font.Size = 6
.SeriesCollection(1).Interior.ColorIndex = 36 'Yellow
.SeriesCollection(2).Interior.ColorIndex = 10 'Green
End With
End Sub
![[neutral] [neutral] [neutral]](/data/assets/smilies/neutral.gif)