SetColumnWidths

Class: TEgFireGrid

procedure SetColumnWidths(const AWidths: array of Single);

Sets the Width of several columns at once.

AWidths: the new widths in FireMonkey units, one entry per column; a negative entry leaves that column as it is. Widths below MinColumnWidth are raised to it. With AutoColumnWidth on, the columns are adjusted to the grid’s width afterwards.

The entries go to the columns of EffectiveColumns in collection order (the order of the columns on screen, hidden columns included), the first entry to the first column; entries beyond the last column are ignored. With no explicit Columns this changes the default columns, which are rebuilt (and lose the change) whenever the dataset’s fields change: use it on explicit columns, or again after each rebuild.

See Also

(C) 2026 Easygate, Lda