MinYValue & MaxYValue not updated even after recalculate

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Frances
Newbie
Newbie
Posts: 14
Joined: Thu Mar 10, 2005 5:00 am
Location: The Netherlands

MinYValue & MaxYValue not updated even after recalculate

Post by Frances » Tue Apr 05, 2005 7:45 am

Hi,
I have two series of horizontalLines added HorizLine and HorizLineSmooth.

HorizLineSmooth.Function = DownSampling
HorizLineSmooth.Datasource = HorizLine

After adding points to HorizLine i do a recalculate and i get a nice HorizLineSmooth. I get MinYValue on HorizLineSmooth which returns the minimum Yvalue. Now i do a Clear() on HorizLine. Now when i try MinYValue on HorizLineSmooth i still get the MinYValue. I do a Recalculate, still no use.

What i really wanted to do is to do a clear() on HorizLine and add new set of points. Now i need to get a MinYValue on new datapoints on HorizLineSmooth. Once the MinYValue is set for HorizLineSmooth it never changes that no matter what i do. I even clear() all the points on HorizLine and on HorizLineSmooth, still i get MinYValue and MaxyValue that was already set. Though the count says zero on HorizLineSmooth, MinYValue is still present.

After putting new points and doing a recalculate the HorizLineSmooth is available. But MinYValue and MaxyValue shows whatever that was already set. It never changes

Is there a way around this!!!

Pep
Site Admin
Site Admin
Posts: 3303
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Thu Apr 07, 2005 7:34 am

Hi,

using the following code works fine here :

Code: Select all

private void Form1_Load(object sender, System.EventArgs e)
{
	horizLine1.FillSampleValues(10);
	smoothing1.Recalculate();
	horizLine1.Clear();
}

private void button1_Click(object sender, System.EventArgs e)
{
	horizLine1.RefreshSeries();
	horizLine1.FillSampleValues(10);			
	smoothing1.Recalculate();
	horizLine1.Clear();			
}

Frances
Newbie
Newbie
Posts: 14
Joined: Thu Mar 10, 2005 5:00 am
Location: The Netherlands

Post by Frances » Thu Apr 07, 2005 10:25 am

Hi,
You are assigning the smooth curve on Line1 and clearing line1. Then you are adding points on line1. THAT WORKS.

What i did is: Assign Line1 to Line2.

HorizLineSmooth.Datasource = HorizLine

Clear HorizLine1. Clear HorizLineSmooth. Now the MinMax for HorizLineSmooth returns the old min max value though there are no points and i called Clear(). HorizLineSmooth.Count still returns 0. Now i add points to HorizLine1. Then i do a recalculate on HorizLineSmooth. Now the minmax is still returning whatever that was already set and not the new MinMax.

[Just reporting the following encountered]

Another BUG: If i set the boundary where max accidently equals min, and doing a recalculate on HorizLineSmooth throws IndexOutOfRange exception.

Cheers,
Bala

Pep
Site Admin
Site Admin
Posts: 3303
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Fri May 13, 2005 9:32 am

Hi Bala,
Clear HorizLine1. Clear HorizLineSmooth. Now the MinMax for HorizLineSmooth returns the old min max value though there are no points and i called Clear(). HorizLineSmooth.Count still returns 0. Now i add points to HorizLine1. Then i do a recalculate on HorizLineSmooth. Now the minmax is still returning whatever that was already set and not the new MinMax.
Yes, you're correct, I'm able to reproduce the problem here. It has been added on our defect list and a fix for it will be considered to inclusion for the next maintenance release. Thanks for the report. In meantime a solution is to remove the Series and create them again.
Another BUG: If i set the boundary where max accidently equals min, and doing a recalculate on HorizLineSmooth throws IndexOutOfRange exception.
Could you please show me how can I reproduce it ?

Post Reply