2

I have a bar chart that will never go below zero (never go negative), 0 y axis. How do I limit panning/scrolling so that the y0 line is always at the base of the graph? The requirement is to not be able to pan below pointy = 0 in view;

agamesh
  • 559
  • 1
  • 10
  • 26
Philip Eki
  • 21
  • 2

1 Answers1

2

Subscribe for ZoomEvent or Scroll event (you must check which one would be more suitable in your situation).

Create a handler for that event and inside of it, check if current pane.YAxis.Scale.Min < 0. If so, change it manually. That should do the trick.

Gacek
  • 10,184
  • 9
  • 54
  • 87