OnGetField
Occur when TField is requested for cell specified by ACol and ARow parameters.property OnGetField: TNxGetFieldEvent read FOnGetField write FOnGetField;If grid request Field, it first access Field property of column. Then it pass reference to this event.
If column have no Field assigned (nil), Field it may be set in-fly inside this event.
Example:
procedure TForm1.NextDBGrid61GetField(Sender: TObject; ACol, ARow: Integer;
var Field: TField);
begin
if ARow = 0 then Field := DataSource1.DataSet.Fields[3];
end;Remarks
Column doesn't need to have associated TField. Value of cell be custom drawn, or calculated from values of other cells.