Developer Barış Atalay from Turkey has released a custom TGridhelper component that adds on some additional functionality to the TGrid component that ships with Delphi XE8 Firemonkey. The main functionality that TGridHelper seems to add is an IncRow function and a Cells property which you can access like a TStrings as far as assigning values to cells in a row. It looks like it was built for Delphi XE7 but should probably work in Delphi XE8 and Appmethod as well. The component is free and available with source from Github. It should work cross platform on Android, IOS, OSX, and Windows. There is also a demo which shows the functionality in action. Additionally it shows how to custom draw each cell in the OnDrawColumnCell event. Here is some sample source code showing the two new ways TGridHelper has of adding content to cells:
procedure TForm8.Button1Click(Sender: TObject);
var I: Integer;
begin
GridHelper1.ClearItems;
for I := 0 to 5 do
begin
GridHelper1.IncRow;
GridHelper1.Cell[I, 0]:= 'sayi ' + I.ToString;
GridHelper1.Cell[I, 1]:= 'sayi ' + I.ToString;
GridHelper1.Cell[I, 2]:= 'sayi ' + I.ToString;
GridHelper1.Cell[I, 3]:= 'sayi ' + I.ToString;
GridHelper1.Cell[I, 4]:= 'sayi ' + I.ToString;
GridHelper1.Cell[I, 5]:= 'Y';
end;
end;
procedure TForm8.Button2Click(Sender: TObject);
var I: Integer;
begin
GridHelper1.ClearItems;
for I := 0 to 5 do
begin
GridHelper1.IncRow;
GridHelper1.AddValue[0]:= 'sayi ' + I.ToString;
GridHelper1.AddValue[1]:= 'sayi ' + I.ToString;
GridHelper1.AddValue[2]:= 'sayi ' + I.ToString;
GridHelper1.AddValue[3]:= 'sayi ' + I.ToString;
GridHelper1.AddValue[4]:= 'sayi ' + I.ToString;
GridHelper1.AddValue[5]:= 'Y';
end;
end;
Head over and download the full source code of this TGridHelper component for Delphi Firemonkey.