Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Setting X-axis properties in VBA code (Graphs)

Status
Not open for further replies.

NVSbe

Programmer
Sep 9, 2002
153
BE
Hi again,

I have another problem concerning graphs (curse the things).
How would I go about accessing the properties of the X-axis of a line graph in the VBA code of the report in which it's embedded. I'd like to set the maximumscale value to something fetched with a query (different from the query that is used to get the data that is displayed in the graph).

The graph is in an OLE-object called oleGraph, so I thought I could probably acess it with

oleGraph.controls(0).axis(0).maximumscale

but I can't. Any thoughts on this?

Thanks in advance,
Niki
 
Ok.. one step further...

Dim tmp as Object
set tmp = oleGraph.Object

tmp should now contain the graph object... I say "should", because it still doesn't seem to, and I still can't acces the X-Axis properties... Any help?
 
...

I'm stupid. Keep it simple and stupid (KISS) seemed to apply here as well, as you can just set properties of the graph to not auto-update the X-axis value. Well, problem solved... :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top