series1.GetVertAxis.SetMinMax with aBothVertAxis does Left

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
SteveP
Advanced
Posts: 132
Joined: Sun Sep 07, 2003 4:00 am

series1.GetVertAxis.SetMinMax with aBothVertAxis does Left

Post by SteveP » Mon Nov 17, 2003 3:15 pm

Peforming series1.GetVertAxis.SetMinMax with axis defined as aBothVertAxis only results in the left axis changing its vertical scale. The right scale remains what is had been.

Marjan
Site Admin
Site Admin
Posts: 745
Joined: Fri Nov 07, 2003 5:00 am
Location: Slovenia
Contact:

Post by Marjan » Mon Nov 17, 2003 5:15 pm

Hi.

True, I get the same results even with the latest TeeChart v7 beta sources. I guess SetMinMax was designed as TChartAxis method and should work only with single axis. In your case the workaround is to manually set right axis scale. I'd place the code in the TChart.OnZoom event. Here is pseudo-code I'd use:
<pre>
if Series1.GetVertAxis = aBothVertAxis then
With Chart1.Axes.Left do
Chart1.Axes.Right.SetMinMax(Minumum,Maximum);
</pre>

Post Reply