Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
900
How to Display whole numbers on the Y-Axis
posted

Hi,

I have an UltraChart 8.1 in my app.  It is set to be a stacked bar chart.  I want the y axis to always show whole numbers (0, 1, 2), but it is splitting the y axis into tickmarks of it's own choosing (0, 0.4, 0.8, 1.2, 1.6, 2).  I saw a post that said I could set the format of the tickmark by setting chart.Axis.Y.Labels.ItemFormatString, but that does not change the intervals, so I ended up with a graph that was marked with rounded intervals (0, 1, 1, 2, 2).  I see that I can set chart.Axis.Y.TickmarkInterval to some number to specify the intervals, but that is not the perfect solution either.  I don't know how large my Y-axis should get - sometimes it may only need to go to 2, other times it could need to go to 100.  It would be nice if I could make it figure out intervals to display automatically, but make sure that they were whole-number intervals.  Is there a way to do that?

Thanks,

~Karen