Library Vcl NextSuite 6 NextGrid6 Reference Classes TNextGrid6 AddChildRow

AddChildRow

Add child row(s) inside parent row.

pas
function AddChildRow(const Index: Integer; const Count: Integer = 1; IgnoreDefaults: Boolean = True): INxCellsRow; overload;
function AddChildRow(ParentRow: INxRow; Count: Integer = 1; IgnoreDefaults: Boolean = True): INxCellsRow; overload;

Parameters

Index
Integer
Indicate Index (zero-based) of parent row inside rows list.

Count
Integer
Specify number of child rows to be added.

IgnoreDefaults
Boolean
DefaultValue of columns will be ignored.

Example

pas
procedure TForm2.Button1Click(Sender: TObject);
var
  NewRow, ChildRow: INxCellsRow;
begin
  NewRow := NextGrid61.AddRow;
  ChildRow := NextGrid61.AddChildRow(NewRow);
  ChildRow.Cells[0].AsString := 'Child';
end;

Remarks

If IgnoreDefault is True the operation of adding rows will be slightly faster.

Sign in