Zoom gone after setting bottom axis max points

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
el1179
Newbie
Newbie
Posts: 5
Joined: Fri Jul 12, 2019 12:00 am

Zoom gone after setting bottom axis max points

Post by el1179 » Tue Jun 16, 2020 8:01 pm

I have a fast line chart that is representing an Oscilloscope. The Bottom axis maximum points vary continuously so I am resetting that value repeatedly. My problem comes in that if I have zoomed in on the graph, the x-axis zooms back out as soon as I change the maximum value and the zoom is lost. How do I get it to "Stick" Thanks.
good1.png
This is before zoom
good1.png (5.85 KiB) Viewed 9506 times
zoomed.png
This is after zoom
zoomed.png (8.19 KiB) Viewed 9506 times
As soon as I run this:
chart.Axes.Bottom.Minimum = 0
chart.Axes.Bottom.Maximum = CurrMaxPoints

It zooms back out. I want it to stay focused on the same area of the graph.

Christopher
Guru
Posts: 1603
Joined: Fri Nov 15, 2002 12:00 am

Re: Zoom gone after setting bottom axis max points

Post by Christopher » Wed Jun 17, 2020 4:10 pm

el1179 wrote:
Tue Jun 16, 2020 8:01 pm
As soon as I run this:
chart.Axes.Bottom.Minimum = 0
chart.Axes.Bottom.Maximum = CurrMaxPoints

It zooms back out. I want it to stay focused on the same area of the graph.
I'd have to see more of your code to have a clear understanding of what's going on, but staying focused on the same area of the graph means choosing very carefully the Minimum and Maximum axis values.
Best Regards,
Christopher Ireland / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Instructions - How to post in this forum

el1179
Newbie
Newbie
Posts: 5
Joined: Fri Jul 12, 2019 12:00 am

Re: Zoom gone after setting bottom axis max points

Post by el1179 » Fri Jun 19, 2020 2:32 pm

The 0-360 are just the labels and the actual points are 0 to anywhere from 5k-30k points. Since that high end changes every second or so I need to keep it up to date to show accurately.

I was able to find a simple suitable workaround where I do not change the bottom axis points when it is zoomed. If zoom cleared they get updated.

Post Reply