Back to Devexpress

GridBand.Fixed Property

windowsforms-devexpress-dot-xtragrid-dot-views-dot-bandedgrid-dot-gridband-64d33d42.md

latest3.3 KB
Original Source

GridBand.Fixed Property

Gets or sets the band’s behavior when the View is scrolled horizontally.

Namespace : DevExpress.XtraGrid.Views.BandedGrid

Assembly : DevExpress.XtraGrid.v25.2.dll

NuGet Packages : DevExpress.Win.Grid, DevExpress.Win.Navigation

Declaration

csharp
[DefaultValue(FixedStyle.None)]
[DXCategory("Behavior")]
[XtraSerializableProperty]
[XtraSerializablePropertyId(3)]
public virtual FixedStyle Fixed { get; set; }
vb
<DXCategory("Behavior")>
<DefaultValue(FixedStyle.None)>
<XtraSerializableProperty>
<XtraSerializablePropertyId(3)>
Public Overridable Property Fixed As FixedStyle

Property Value

TypeDefaultDescription
FixedStyleNone

A FixedStyle enumeration member specifying the band behavior when the View is scrolled horizontally.

|

Available values:

NameDescription
None

The band or column takes part in horizontal scrolling.

| | Left |

The band or column is anchored to the View’s left edge.

| | Right |

The band or column is anchored to the View’s right edge.

| | MiddleLeft |

The band or column is not anchored until a user scrolls it up to the left edge. When the column reaches the left edge, it becomes fixed while other columns continue to scroll. This style is not supported for bands.

|

Remarks

There may be situations when you need to always display a band’s content regardless of the scrolling applied to the View. In this case, you need to set the band’s GridBand.Fixed property to FixedStyle.Left or FixedStyle.Right. This will anchor the band to the left or right View edge respectively. Such bands are not moved when horizontal scrolling is performed.

The image below shows a banded View with a single band anchored to each View edge.

Note that the GridBand.Fixed property is unimportant when the columns auto width feature is enabled or when the total column width is less than the View’s width. In such cases, the Fixed property value is ignored. Please refer to the Banded Grid Views topic for additional information.

See Also

FixedLineWidth

FixedColumnHighlightMode

GridBand Class

GridBand Members

DevExpress.XtraGrid.Views.BandedGrid Namespace