Using the ZedGraph control, say I am plotting data that has Y values of 13, 34, and 55.
How do I set up my Y Axis so that the only text labels shown (and I guess that grid lines would be synchronised) are those for 13, 34 and 55?
I don’t want regularly spaced labels in the range of my data (say 0, 25, 50, 75, ..). Just labels at the actual values.
I don’t think it is possible directly, out of the box.
Here’s some poor half-solution created using custom TextObj labels.
First, you need to disable the old axis scale:
Then, you need to create custom labels. If y_vals is the array of your Y-values:
You can create your custom grid-lines just in the same way using LineObj. Just add this inside the foreach loop: