How To Change Fonts In Multiple Charts in a Workbook?

C

Cweed

I have a workbook with approx 120 charts spread out over 30 worksheets.
Each worksheet has 4 charts on it.
Each of the 4 charts has different data and Values.
I would like them all to have the same fonts (made the mistake of no
checkin when I produced the charts originaly ) but the X axis an
coloring is different in each of the 4 charts. I have tried copying th
"formats" but this changes everying in the chart but the data itself.

Is there a macro to help with this or possibly something easier that
am over looking?

Thank
 
J

Jon Peltier

Untested, but this is about how it would look:

Sub ChangeChartFonts()
Dim sh As Object
Dim ch As Chart
Dim co As ChartObject

' chart sheets
For Each ch In ActiveWorkbook.Charts
ch.ChartArea.Font.Name = "Arial"
Next

' chart objects embedded on sheets
For Each sh In ActiveWorkbook.Sheets
For Each co In sh.ChartObjects
co.Chart.ChartArea.Font.Name = "Arial"
Next
Next

End Sub


- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services
Tutorials and Custom Solutions
http://PeltierTech.com/
_______
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top