Hello!
I'm facing problems populating a ColorGrid!
I want to add values like this:
this.colorGrid1.Add(4.2, 4.3, 5.5);
this.colorGrid1.Add(5.3, 3.1, 5.5);
this.colorGrid1.Add(4.2, -2.5, 6.2);
this.colorGrid1.Add(5.3, 1.0, 6.2);
It is unavoidable to add floating point numbers and they have to be displayed accurately.
But what I get running this example is a "System.IndexOutOfRangeException".
Have you got any advice? Should I use a different control?
Many thanks in advance!
Floatingpoint numbers in ColorGrid
-
- Newbie
- Posts: 20
- Joined: Fri Dec 05, 2003 5:00 am
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hello dotnetjunkee,
Which TeeChart version are you using? It works fine for me here using latest debug build release from 9th June 2006. This debug build is available at the customer area, can you please test if it works at your end?
Which TeeChart version are you using? It works fine for me here using latest debug build release from 9th June 2006. This debug build is available at the customer area, can you please test if it works at your end?
Best Regards,
Narcís Calvet / 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 |
-
- Newbie
- Posts: 20
- Joined: Fri Dec 05, 2003 5:00 am
I'm using version 1.1.2307.20497.
Unfortunately it does not work with a Surface-style either.
What i've found out so far is that the following lines work fine:
this.colorGrid1.Add((double)0.0, (double)1.0, (double)1.0);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)0.0, (double)1.0, (double)2.0);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)2.0);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)2.0);
But these lines of code do not work:
this.colorGrid1.Add((double)0.0, (double)1.0, (double)1.0);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)0.0, (double)1.0, (double)3.2);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)3.2);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)3.2);
It seems to me that each single step has to be added (1, 2, 3,...) But this is not possible due to my data
Unfortunately it does not work with a Surface-style either.
What i've found out so far is that the following lines work fine:
this.colorGrid1.Add((double)0.0, (double)1.0, (double)1.0);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)0.0, (double)1.0, (double)2.0);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)2.0);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)2.0);
But these lines of code do not work:
this.colorGrid1.Add((double)0.0, (double)1.0, (double)1.0);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)0.0, (double)1.0, (double)3.2);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)3.2);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)3.2);
It seems to me that each single step has to be added (1, 2, 3,...) But this is not possible due to my data
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi dotnetjunkee,
It works fine for me here using the same TeeChart for .NET version as you and setting IrregularGrid to true:
It works fine for me here using the same TeeChart for .NET version as you and setting IrregularGrid to true:
Code: Select all
this.colorGrid1.Add((double)0.0, (double)1.0, (double)1.0);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)1.0);
this.colorGrid1.Add((double)0.0, (double)1.0, (double)3.2);
this.colorGrid1.Add((double)1.0, (double)3.0, (double)3.2);
this.colorGrid1.Add((double)2.0, (double)3.0, (double)3.2);
this.colorGrid1.IrregularGrid=true;
Best Regards,
Narcís Calvet / 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 |
-
- Newbie
- Posts: 20
- Joined: Fri Dec 05, 2003 5:00 am
Thank you
Thank you!
It works fine here now as welL!
It works fine here now as welL!