Skip to main content
All docs
V24.2

GridColumnCollection.ForEach(Action<GridColumn>) Method

Executes the specified action on each element in the collection.

Namespace: DevExpress.XtraGrid.Columns

Assembly: DevExpress.XtraGrid.v24.2.dll

Declaration

public void ForEach(
    Action<GridColumn> action
)

Parameters

Name Type Description
action Action<GridColumn>

The delegate to execute on each element in the collection.

Remarks

The code below converts the captions of all column headers to uppercase.

gridView1.Columns.ForEach(column => column.Caption = column.Caption.ToUpper());
See Also