Skip to main content

BaseColumn.HeaderToolTipTemplate Property

Gets or sets the template that defines the tooltip’s presentation. This is a dependency property.

Namespace: DevExpress.Xpf.Grid

Assembly: DevExpress.Xpf.Grid.v23.2.Core.dll

NuGet Package: DevExpress.Wpf.Grid.Core


public DataTemplate HeaderToolTipTemplate { get; set; }

Property Value

Type Description

A DataTemplate object that defines the presentation of a column header’s tooltip.


A header tooltip contains the column header’s text by default. The image below shows a grid column with a modified text in the header tooltip:


Specify the BaseColumn.HeaderToolTip property to change the tooltip’s text. The following code sample shows how to use this property to specify custom text:

<dxg:GridColumn FieldName="CategoryName" HeaderToolTip="Category"></dxg:GridColumn>

If the BaseColumn.HeaderToolTip property is specified, a tooltip is automatically displayed when an end-user hovers the mouse pointer over a column header. Otherwise, a tooltip is displayed for a column header if its caption is clipped.

The image below shows a grid column with a header tooltip that contains an image before the text:


Specify the HeaderToolTipTemplate property to add custom content to an individual column’s tooltip. Use the DataViewBase.ColumnHeaderToolTipTemplate property to specify a common tooltip template for all the columns in the current GridControl’s view. The BaseColumn.HeaderToolTip property is the data context (binding source) for these templates.

The following code sample shows how to add an image to a tooltip using the HeaderToolTipTemplate property:

<dxg:GridColumn FieldName="CategoryName">
            <Image Source="Image.png" Margin="0,0,5,0"></Image>
            <TextBlock Text="{Binding TemplatedParent.DataContext.HeaderCaption, RelativeSource={RelativeSource TemplatedParent}}" />

Use the BaseColumn.ActualHeaderToolTipTemplate property to obtain a column’s current tooltip template.

See Also