Skip to main content

Custom Column

FdcCustomColumn lets application code fully customize the cell widget while still keeping field binding, sorting, filtering, export, and dataset integration.

Custom column sample
Loading FDC sample…
FdcGrid(
dataSet: accountRows,
options: const FdcGridOptions(readOnly: true),
columns: [
const FdcTextColumn(fieldName: 'account', width: 200),
const FdcTextColumn(fieldName: 'plan', width: 120),
FdcCustomColumn<int>(
fieldName: 'health',
width: 220,
readOnly: true,
showIndicator: false,
cellBuilder: buildHealthCell,
),
],
);

Key characteristics

  • Still field-bound: the column works on a real dataset field.
  • Gives you FdcFieldContext and FdcCellContext so you can read, format, and write values through the normal grid pipeline.
  • Good for custom visuals, composite cells, and specialized controls.

Example

FdcCustomColumn<int>(
fieldName: 'health',
readOnly: true,
showIndicator: false,
cellBuilder: buildHealthCell,
)