QueryCellsReturns TNxCells6 object based on result of specified query.
function QueryCells(Query: WideString): TNxCells6;
Grid's main Cells object remain intact, but new TNxCells6 object (referencing same Grid) is created. TNxCell6 object may be assigned to target Grid via CellSource property of TNextGrid6.
colSalary >= 10000 or colSalary <= 20000 colFirstName = "Ann" and colActive = False
procedure TForm3.Button1Click(Sender: TObject); const s = 'colSalary > 20000 and colActive = True'; var Cells: TNxCells6; begin // Query first Grid Cells := NextGrid61.QueryCells(s); // Fill second Grid with result NextGrid62.CellSource := Cells; end;
TNxCells6 object may be read by using its methods such as Cell[ACol, ARow], Row[Index], RowCount etc.
if Cells.RowCount = 1 then begin MyVar := Cells.Cell[0, 0].AsFloat; end;