GridColumn.Caption Property

Gets or sets the column's display caption. This is a bindable property.

Namespace: DevExpress.Mobile.DataGrid

Assembly: DevExpress.Mobile.Grid.v18.2.dll


public string Caption { get; set; }
Public Property Caption As String

Property Value

Type Description

A String value specifying the column's display caption.



This documentation topic describes legacy technology. We no longer develop new functionality for the GridControl and suggest that you use the new DataGridView control instead.

In the grid, column captions are displayed in column headers.

By default, the Caption property is set to an empty string. In this case, a friendly caption is generated for a column based on its GridColumn.FieldName property. Friendly captions are generated by adding SPACE characters between parts of the field name starting with uppercase letters. For example, if the field name is "CustomerName", the display caption will be "Customer Name". To obtain a column caption as it is displayed in a column header, use the GridColumn.ActualCaption property.

To override the default display caption, assign it to the Caption property.

To control the visibility of column headers in the GridControl, use the GridControl.ColumnHeadersVisibility property.


This example shows how to create and customize grid columns for displaying and editing data of different types (text, numbers, dates and Boolean values). The specified collection contains columns bound to the data source fields (Product.Name, Product.UnitPrice, Quantity, Date and Shipped) and one unbound column (Total) displaying data values calculated according to a formula based on the values of other columns.

The image below illustrates the result.



See Also