Page 1 of 1

Problem ColorGrid with a double value

Posted: Thu Jul 10, 2008 1:33 pm
by 7663900
I have a big trouble when i try to setting a double value with a ColorGrid.
I set successfully with a indice table of value if work very fine
but when i try to set a double value is not work !!
exemple:
tab[0] =1.114; tab1[0] = 55,5;
tab[1] =1.256; tab1[1] = 60,5;
tab[3] = 1.356;
lX = tab[0];
.....
lZ = tab1[0];
.....
fColorGrid.add(lX ,lValue , lZ); // NO WORK
//fColorGrid.add(i, lValue ,j); // WORK FINE

thanks per advance
jerome H

some more information

Posted: Thu Jul 10, 2008 1:45 pm
by 7663900
i have this error
fListPositions size =92
fListAngles size =123
Exception in thread "AWT-EventQueue-0" java.lang.ArrayIndexOutOfBoundsEx
ception: -1
at com.steema.teechart.styles.ValueList.getValue(ValueList.java:
430)
at com.steema.teechart.styles.ColorGrid.drawGrid(ColorGrid.java:
162)
at com.steema.teechart.styles.ColorGrid.draw(ColorGrid.java:261)
at com.steema.teechart.styles.Series.drawSeries(Series.java:2222
)
at com.steema.teechart.Chart.internalDraw(Chart.java:670)
at com.steema.teechart.Chart.paint(Chart.java:1807)
at com.steema.teechart.TChart.paintComponent(TChart.java:571)

Posted: Thu Jul 10, 2008 2:31 pm
by narcis
Hi IPHC,

First of all, please notice that you need to populate ColorGrid series as I described on this thread.

If the problem still persists please send us a code snippet or a simple example project we can run "as-is" to reproduce the problem here.

You can either post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.

Thanks in advance.

It's works perfect Now !!

Posted: Fri Jul 11, 2008 2:23 pm
by 7663900
I just add a test for viewing if my grid is or isn't irregular

if (lXinc != lZinc )
fColorGrid.setIrregularGrid(true);
else
fColorGrid.setIrregularGrid(false);

and after fColorGrid.add(lX,lValue,lZ);

GOOD and thanks all for this help

bye