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

XRControl.AnchorHorizontal Property

Specifies the horizontal anchoring style of a report control.

Namespace: DevExpress.XtraReports.UI

Assembly: DevExpress.XtraReports.v17.2.dll

NuGet Package: DevExpress.Reporting.Core

Declaration

[SRCategory(ReportStringId.CatBehavior)]
public virtual HorizontalAnchorStyles AnchorHorizontal { get; set; }

Property Value

Type Description
HorizontalAnchorStyles

A HorizontalAnchorStyles enumeration member, specifying the side of the control’s container.

Available values:

Name Description
None

A control is not anchored to any edge of its container.

Left

A control is anchored to the left edge of its container.

Right

A control is anchored to the right edge of its container.

Both

A control is anchored to both the left and right edges of its container.

Remarks

The AnchorHorizontal property attaches a report control to the specified side(s) of its container (left, right, or both) on a rendered document page. This property defines how a report control is resized to maintain the distance to the left and right edges of its container control.

To apply the horizontal anchoring in Print Preview, handle the corresponding events of the PrintingSystem class (PrintingSystemBase.PageSettingsChanged or PrintingSystemBase.AfterMarginsChange), apply updated page settings to the report and create a document.

The property is hidden in the following descendants of the XRControl class:

See Also