----- Original Message -----
From: "Mariano" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Wednesday, May 03, 2006 10:52 AM
Subject: [lazarus] TStringGrid Range check error: Accessing non visibles
cells
Hi!
i'm developing an application using the TStringGrid to show some data and
store another...
but, when i made this in Delphi, i used hiden columns to store additional
data that I need...
and now, trying to port this into lazarus, i have a Range check
exception...
for instance:
in delphi, i wrote:
// fGrid is TStringGrid
fgrid.Colcount:=4;
fgrid.Rowcount:=2;
fgrid.Cells[1,1]:='column 1';
fgrid.Cells[2,1]:='column 2';
fgrid.Cells[3,1]:='column 3';
fgrid.Cells[4,1]:='column 4: Hiden information';
And run without problems, storing all data ok.
And If i write later:
s:=fgrid.Cells[4,1];
i get 'column 4: Hide information'
that is OK!
I didn't know that you could do that.
but in lazarus, just here:
fgrid.Cells[4,1]:='column 4: Hide information';
I have and exception...
I understand that it's logical, but delphi allows me this kind of stuff...
why lazarus doesn't allow me this?
To me it looks like a bug in Delphi, or is it a feature?. If it is a feature
is it documented somewhere?.
Either a bug or a feature I think this will not be implemented in Lazarus'
grids, but you can very easy obtain the same by doing:
fgrid.Colcount := 5;
fgrid.ColWidths[4]:=0;
fgrid.Cell[4,1] := 'column 4: Hiden information';
Mariano
20 años
Argentina
Jesus Reyes A.
__________________________________________________
Correo Yahoo!
Espacio para todos tus mensajes, antivirus y antispam ¡gratis!
Regístrate ya - http://correo.yahoo.com.mx/
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives