DataViewBase.CellStyle Property

Gets or sets the style applied to data cells displayed within a View. This is a dependency property.

Namespace: DevExpress.Xpf.Grid

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


public Style CellStyle { get; set; }
Public Property CellStyle As Style

Property Value

Type Description

The style applied to data cells.


The CellStyle property specifies the style that groups together properties, resources, and event handlers and shares them between instances of the LightweightCellEditor type.

Target Type:

        <Style TargetType="dxg:LightweightCellEditor" />

The GridControl's CellStyle property is theme dependent. Create a new style based on the existing cell style to apply a CellStyle. For example, if you use the MetropolisDark theme, your style's BasedOn property should be set to the following value:

    <Style TargetType="dxg:LightweightCellEditor" BasedOn="{StaticResource {dxgt:GridRowThemeKey ResourceKey=LightweightCellStyle, ThemeName=MetropolisDark}}"/>
See Also