Skip to main content
A newer version of this page is available. .

GridColumn Class

Represents an individual column in Grid Views and Card Views.

Namespace: DevExpress.XtraGrid.Columns

Assembly: DevExpress.XtraGrid.v18.2.dll

Declaration

public class GridColumn :
    Component,
    IAppearanceOwner,
    IXtraSerializableLayoutEx,
    ISupportLookAndFeel,
    IDataColumnInfoProvider,
    ISupportDXSkinColorsEx,
    ISupportDXSkinColors

The following members return GridColumn objects:

Show 68 links
Library Related API Members
WinForms Controls BandedGridView.AutoFillColumn
CardHitInfo.Column
CellMergeEventArgs.Column
CellValueChangedEventArgs.Column
ColumnEventArgs.Column
ColumnHeaderCustomDrawEventArgs.Column
ColumnView.FocusedColumn
ColumnView.GetNearestCanFocusedColumn(GridColumn)
ColumnView.GetVisibleColumn(Int32)
CustomColumnDataEventArgs.Column
CustomColumnDisplayTextEventArgs.Column
CustomColumnSortEventArgs.Column
CustomFilterDialogEventArgs.Column
CustomRowCellEventArgs.Column
EditFormValidateEditorEventArgs.Column
FieldHeightEventArgs.Column
FilterPopupEventArgs.Column
FocusedColumnChangedEventArgs.FocusedColumn
FocusedColumnChangedEventArgs.PrevFocusedColumn
GridCell.Column
GridColumnCollection.Add()
GridColumnCollection.AddField(String)
GridColumnCollection.AddVisible(String, String)
GridColumnCollection.AddVisible(String)
GridColumnCollection.ColumnByFieldName(String)
GridColumnCollection.ColumnByName(String)
GridColumnCollection.Insert(Int32)
GridColumnCollection.Item[Int32]
GridColumnCollection.Item[String]
GridColumnReadOnlyCollection.Item[Int32]
GridColumnSortInfo.Column
GridFormatRule.Column
GridFormatRule.ColumnApplyTo
GridGroupSummaryItem.ShowInGroupColumnFooter
GridHitInfo.Column
GridMenuItemClickEventArgs.Column
GridView.AddUnboundColumn()
GridView.AddUnboundColumn(String, String)
GridView.AutoFillColumn
GridView.PressedColumn
GroupSummarySortInfo.GroupColumn
LayoutView.FocusedColumn
LayoutViewFieldCaptionImageEventArgs.Column
LayoutViewHitInfo.Column
RowCellClickEventArgs.Column
RowCellCustomDrawEventArgs.Column
RowCellObjectCustomDrawEventArgs.Column
StyleFormatCondition.Column
TileViewColumns.BackgroundImageColumn
TileViewColumns.CheckedColumn
TileViewColumns.EnabledColumn
TileViewColumns.GroupColumn
TileViewItemElement.Column
WinExplorerView.GetColumn(WinExplorerViewFieldType)
WinExplorerViewColumns.CheckBoxColumn
WinExplorerViewColumns.DescriptionColumn
WinExplorerViewColumns.EnabledColumn
WinExplorerViewColumns.ExtraLargeImageColumn
WinExplorerViewColumns.ExtraLargeImageIndexColumn
WinExplorerViewColumns.GroupColumn
WinExplorerViewColumns.LargeImageColumn
WinExplorerViewColumns.LargeImageIndexColumn
WinExplorerViewColumns.MediumImageColumn
WinExplorerViewColumns.MediumImageIndexColumn
WinExplorerViewColumns.SmallImageColumn
WinExplorerViewColumns.SmallImageIndexColumn
WinExplorerViewColumns.TextColumn
eXpressApp Framework ColumnCreatedEventArgs.Column

Remarks

GridColumn objects represent columns and card fields in Grid Views and Card Views respectively. Such objects are used to display data from an individual data field. The bound data field is specified by the GridColumn.FieldName property. Settings provided by the GridColumn class also allow you to control how column data is displayed and edited, column header contents, the column’s position and visibility, etc. Note that some of the settings provided are in effect only for columns displayed in Grid Views. For instance, the GridColumn.GroupIndex and GridColumn.SummaryItem properties are in effect for Grid View columns only, as Card Views do not support the grouping and summary features.

You can access a View’s column collection using the ColumnView.Columns property. This property returns an object whose indexer can be used to access individual GridColumn objects. Note also that column objects are Component descendants. This enables you to access columns in code directly by their names.

You don’t need to create column objects manually using the GridColumn class constructor. Columns can be created using methods of the owning column collection (GridColumnCollection class) or by using the ColumnView.PopulateColumns method of the required View.

For additional information regarding columns, refer to the Columns article.

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the GridColumn class.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also