Page 1 of 1

Missing Y axis major tick labels

Posted: Mon Feb 13, 2017 9:51 am
by lukoprovandrey
Hello guys,

I have an issue related to Y axis tick labels. If I decrease chart height I would see rounding(beautiful :D ) minimum, maxim and average labels on a Y axis, like on the picture below:
11111.png
11111.png (2.05 KiB) Viewed 8767 times

I tried to change some properties, but it didn't help. Also, we tried to use custom tick, but we need to round values like in automatic mode. Do you have any idea how we can set any properties to always see min and max labels?

see https://www.screencast.com/t/bBhywpzhVL for best understanding.

Re: Missing Y axis major tick labels

Posted: Mon Feb 13, 2017 7:19 pm
by ArctionPasi
Hello :)

I think there's not built-in feature for that.

Maybe in Chart.SizeChanged event handler, you could investigate graph segment's height, by chart.GetGraphSegmentInfo().SegmentHeight. If it's small, switch to use CustomAxisTicks. Add 3 Ticks with your preferred values, and labels. Remember to set axis.AutoFormatLabels = false, so labels will be outputted as text you give to CustomAxisTicks.