How to dynamically set the lower and upper limits of the axes scaleson a MS Access xy-chart

B

biker

Does anybody know if there is a way to dynamically set the lower and
upper limits of the axes scales on a MS Access xy-chart using the
underlying
minimum and maximum values in the data series used to build that
chart?

I have a chart acting as a subform in a main form. The subform is
linked to the main form by a date field. So when the main form shows
a
particular day, the subform shows only the data series for that
particular day in the chart. Now I would like to set the minimum and
maximum values of the xy-chart's axes scaling in such a way that on
each day the minimum and maximum values of the axes are dynamically
set according to the minimum and maximum values of the data series of
that particular day. In this way the chart area will be used much
more
efficiently than when using automatic scaling.

I would like to know if this is somehow possible within MS Access.

Any help would be very much appreciated.
 
B

biker

Hi Biker.  

Sorry we've been slow to reply to this.  It's probably because the
charting/graphing feature is very hard to work with.  I suspect that you can do
what you want, since it seems almost all the properties available in the GUI
are also available in code.  But it will take a lot of trial and error,if my
experience is any guide.

Karl

Hi Karl,

Thanks for the reply. And it hasn't been slow at all. But I don't
understand where your answer is pointing to. I'm a novice to VBA, so I
really can't come up with some code to begin with. I've searched
through several posts that seem to address my issue, but I can't
translate their propositions to my own situation. I also can't say if
those propositions are correct, since hardly anybody makes a final
evaluation about how effective the proposition was. A lot of people
seem to come up with some lines they picked op somewhere on the
internet and they seem to just pass them on without showing much
understanding. I think I also tried out everything there is in the MS
Access GUI, but there doesn't seem to be anything that I can use for
my situation.

I suppose that you already understand my problem. I want to se the
axes' scaling limits to the two most extreme values in my data series
(minimum and maximum values). This is the problem. The X-axis has a
time scale (time interval between a starting point and an end point).
On the Y-axis I plot the dependent variable, which is some weather
statistic (temperature, wind speed, wind direction, etc). Within the
observed time interval these weather statistics also have a lower
limit and an upper limit. I want to use these lower and upper limits
as minimum and maximum limits of the Y-axis. Using automatic scaling
in the MS Access GUI leads to very undesirable behavior of the width
of the axes. Sometimes the scaling is done fairly well, so that the
graph uses a large proportion of the chart area. But most of the times
the scaling intervals that the chart creates are far too wide, so that
the graph becomes very narrow and/or flat in the chart area. So the
real problem is that the automatic scaling feature in MS Access (or MS
Graph) just doesn't do the job as it should. For the solution, I
imagine to take the minimum and maximum values of the data series and
to tell MS Access (or MS Graph) explicitly to use these values as
lower and upper limits of the X-axis and Y-axis scaling. The problem
that I'm left with is: how to tell this to MS Access (or MsGraph)?

I'll be glad to provide more technical (database-specific)
information, if you think you need that to solve this problem. To me
this a problem that I really want to solve, because it's quite
annoying not to be able to set up my charts like I want to.

Ron
 
B

biker

Hi Biker.  

Sorry we've been slow to reply to this.  It's probably because the
charting/graphing feature is very hard to work with.  I suspect that you can do
what you want, since it seems almost all the properties available in the GUI
are also available in code.  But it will take a lot of trial and error,if my
experience is any guide.

Karl


Hi Karl,

Thanks for the reply. And it hasn't been slow at all. But I don't
understand where your answer is pointing to. I'm a novice to VBA, so I
really can't come up with some code to begin with. I've searched
through several posts that seem to address my issue, but I can't
translate their propositions to my own situation. I also can't say if
those propositions are correct, since hardly anybody makes a final
evaluation about how effective the proposition was. A lot of people
seem to come up with some lines they picked op somewhere on the
internet and they seem to just pass them on without showing much
understanding. I think I also tried out everything there is in the MS
Access GUI, but there doesn't seem to be anything that I can use for
my situation.


I suppose that you already understand my problem. I want to se the
axes' scaling limits to the two most extreme values in my data series
(minimum and maximum values). This is the problem. The X-axis has a
time scale (time interval between a starting point and an end point).
On the Y-axis I plot the dependent variable, which is some weather
statistic (temperature, wind speed, wind direction, etc). Within the
observed time interval these weather statistics also have a lower
limit and an upper limit. I want to use these lower and upper limits
as minimum and maximum limits of the Y-axis. Using automatic scaling
in the MS Access GUI leads to very undesirable behavior of the width
of the axes. Sometimes the scaling is done fairly well, so that the
graph uses a large proportion of the chart area. But most of the times
the scaling intervals that the chart creates are far too wide, so that
the graph becomes very narrow and/or flat in the chart area. So the
real problem is that the automatic scaling feature in MS Access (or MS
Graph) just doesn't do the job as it should. For the solution, I
imagine to take the minimum and maximum values of the data series and
to tell MS Access (or MS Graph) explicitly to use these values as
lower and upper limits of the X-axis and Y-axis scaling. The problem
that I'm left with is: how to tell this to MS Access (or MsGraph)?

If you can come up with some VBA code that will address this problem,
maybe that will help me to solve this important problem. I'll be glad
to provide more technical (database-specific) information, if you
think you need that to solve this problem. To me this a problem that I
really want to solve, because it's quite annoying not to be able to
set up my charts like I want to.

Ron
 
B

biker

Anybody who ever succeeded in dynamically setting the lower and upper
limits of the axes scales on a MS Access xy-chart (using MS Graph),
depending on the values in the underlying data series?
 

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