Resizing Chart Width and Height

  • Thread starter Thread starter Kelly
  • Start date Start date
K

Kelly

This might be a dumb question, but is there any way to
resize a chart's height and width to specific measurements
in Excel? I would like to put 3 charts on a page and make
them the same height and width. I have exported them to
Word and been able to adjust them there but was wondering
if there was a way to eliminate this step.
Thanks...
 
If the charts are in a worksheet, you can select the charts as object
and size them directly:
press control and click on the chart to select as a object
clicking format, object, size takes you to a dialogue box to set siz
directly.

or, you can set the sizes of all charts using a simple macro:

Sub set_charts_size()
For Each ss In ActiveSheet.ChartObjects
ss.Height = 170 ‘height in points
ss.Width = 220 ‘width in points
Next
End Su
 
That is great! Thank you. Do you know if there is any
way to do the same for the plot area?
Thanks...
 
Hi Kelly,
The code is similar, but you must activate the charts:

Sub set_charts_plotarea_size()
For Each ss In ActiveSheet.ChartObjects
ss.Activate
ActiveChart.PlotArea.Height = 220
ActiveChart.PlotArea.Width = 240
Next
End Sub
 
Nicky said:
*
Sub set_charts_size()
For Each ss In ActiveSheet.ChartObjects
ss.Height = 170 ‘height in points
ss.Width = 220 ‘width in points
Next
End Sub *

I fairly new at this so this may seem dumb, what is the "ss" in th
code above, is an undeclared variable
 
That's a dummy variable Nicky was using for the chartobjects. Strictly
speaking, there should be a line that reads

Dim ss As ChartObject

at the top of the procedure or at the top of the module.

- Jon
 
Back
Top