Pie Chart Window - too much white space

G

Guest

How do I set how big the ''chart window'' is for a pie chart

When I create a pie chart there is over 2 inches of white space to the left and right of the pie itself, and more than 1 inch of wasted space above. I can resize each chart window by dragging the corners, however this resizes the text and the pie. Also, I have about 50 charts to make so it would be better is the chart window size was automatic

Any ideas

Thanks
Kathy
 
N

Nicky

To prevent the font size from changing when the pie size changes, se
asutoscalefont to false

The following code should do this,and also make the pie as large a
possible relative to your chart area size. Note that it moves the pi
itself to the top left of the chart area.

Sub format_pie()
ActiveChart.ChartArea.AutoScaleFont = False
chart_size
Application.WorksheetFunction.Min(ActiveChart.ChartArea.Width
ActiveChart.ChartArea.Height)
ActiveChart.PlotArea.Top = 0
ActiveChart.PlotArea.Left = 0
ActiveChart.PlotArea.Select
Selection.Height = chart_size
Selection.Width = chart_size
End Su
 
N

Nicky

Hi,

If you are inserting charts in excel as eg pictures from somewher
else, this code won't help - try cropping the picture instead.

If you have created the chart in excel and it is located on
worksheet, try the following:

Activate the chart, then click format, selected chart area, select th
font tab, then uncheck the atoscalefont box.

to resize the chart, select the plot area (click close to but jus
outside the edge of the pie), and drag on a corner to expand it. It ca
be sized up to the width or height of your chart area (the box th
chart, legend, titles etc are in), whichever is smaller.

You might also want to move the pie to the bottom and/or left of th
chart area, to allow it to fill more of the available space.

If you record these key strokes as you do this as a macro, you can the
repeat the process for your other charts.

The attached shows a pie chart whose plot area (filled pale yellow
almost completely fills its chart area (the red box)

Attachment filename: pie eg.xls
Download attachment: http://www.excelforum.com/attachment.php?postid=50497
 

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