Calling DoZoom

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Mike Jones
Advanced
Posts: 192
Joined: Thu Feb 01, 2007 12:00 am
Contact:

Calling DoZoom

Post by Mike Jones » Wed Dec 09, 2009 11:00 pm

I am seeing an issue when I call the DoZoom method on my 2D chart.

I have a chart, I zoom in similar to how you can zoom in the example project at Welcome !\Miscellaneous\Zoom and Scroll\Direction where I can zoom both directions.

Once zoomed in I do something in my application where I
1. Save the Left & Bottom Axis min/max values
2. Remove the chart control from my dialog
3. Re-generate the chart
4. Then I want to apply the zoom settings I saved off in step 2

Notice I say zoom, because I want to be able to press the "Normal" button on the ChartController toolbar to restore the zoom back to what it was originally drawn to.

The problem I have been having is it seems the values I send to the the DoZoom method are not quite right. I send in something that looks like:

Code: Select all

Chart.DoZoom(_xZoom.Min, _xZoom.Max, _xZoom.Min, _xZoom.Max, _yZoom.Min, _yZoom.Max, _yZoom.Min, _yZoom.Max);
where _xZoom & _yZoom are structures holding the Bottom & Left axis min/max values from step 1.

When I hit the Normal button on the Chart Controller I see the Left axis zoom out 2x what it should have. Not sure why. I assume it is because I am passing some incorrect arguments into the DoZoom method.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Re: Calling DoZoom

Post by Narcís » Tue Dec 15, 2009 11:49 am

Hi Mike,

Could you please attach a simple example project we can run "as-is" to reproduce the problem here?

Thanks in advance.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply