I have a DBGrid
and use it to get data into a Array
. But as soon as I press the button to do this procedure I get a StackOverFlow error ? Here is the Code I use :
iRy := 0;
iCol := DBGrid.Columns.Count;
sTest := DBGrid.Columns[0].Field.AsString;
While sTest <> '' do
begin
for k := 1 to iCol do
begin
arrData[iRy+1,iCol] := DBGrid.Columns[iCol].Field.AsString;
end;
Inc(iRy);
DBGrid.DataSource.DataSet.Next;
sToets := DBGrid.Columns[0].Field.AsString;
end;
I am using Delphi 7 .