scaling chart x and y axis


Posted by Gernot on June 11, 2001 3:57 AM

I want to change the x and y axis of a chart using spinnbuttons. So far so good, but how do I acess the x or y minimum and maximum values in VBA?

Thanks, Gernot



Posted by Ben O. on June 11, 2001 7:54 AM

Try something like this:

MinValueY = Application.WorksheetFunction.Min(yRange)

MaxValueX = Application.WorksheetFunction.Max(xRange)

You would have to assign your range of y values to yRange and your range of x values to xRange. I didn't test this. I hope it works.

-Ben