Changing a chart scale using a formula/macro

D

Doug

Is it possible to change the scale (min & max of the Y axis) of a chart
using a formula or macro. I need to be able to apply this to about 20
different sets of min & max numbers on the same chart.

Thanks,
Doug
 
J

Jon Peltier

Doug -

The code is like this:

With ActiveChart.Axes(2,1)
.MinimumScale = <new minimum>
.MaximumScale = <new maximum>
End With

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

Doug

Thanks,
Doug

Jon Peltier said:
Doug -

The code is like this:

With ActiveChart.Axes(2,1)
.MinimumScale = <new minimum>
.MaximumScale = <new maximum>
End With

- 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