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

ReportSettingsBase.ReportUnit Property

Specifies units to measure locations, dimensions and margins in the report.

Namespace: DevExpress.XtraReports.UserDesigner

Assembly: DevExpress.XtraReports.v19.1.dll

NuGet Packages: DevExpress.Reporting.Core, DevExpress.WindowsDesktop.Core

Declaration

[DefaultValue(ReportUnit.HundredthsOfAnInch)]
public ReportUnit ReportUnit { get; set; }

Property Value

Type Default
ReportUnit **HundredthsOfAnInch**

Available values:

Name Description
HundredthsOfAnInch

The unit of measurement is in hundredths of an inch.

TenthsOfAMillimeter

The unit of measurement is in tenths of a millimeter.

Pixels

The unit of measurement is in pixels (one pixel equals 1/96 of an inch).

Remarks

The ReportUnit property specifies the measurement units to use for XRControl.SizeF and Band.LocationF property types.

Only the XRControl.BorderWidth property value is expressed in ReportUnit.Pixels.

See the Report Units of Measurement topic for a complete list of properties this option affects.

The code sample below illustrates how to create an End-User Designer instance and set the ReportUnit property default value for its reports.

using DevExpress.XtraReports.UI;
using DevExpress.XtraReports.UserDesigner;
// ...
XRDesignForm form = new XRDesignForm();
XRDesignMdiController reportDesigner = form.DesignMdiController;
reportDesigner.DefaultReportSettings.PaperKind = System.Drawing.Printing.PaperKind.Letter;
reportDesigner.DefaultReportSettings.Landscape = true;
reportDesigner.DefaultReportSettings.RollPaper = false;
reportDesigner.DefaultReportSettings.ReportUnit = ReportUnit.HundredthsOfAnInch;
reportDesigner.DefaultReportSettings.Margins = new System.Drawing.Printing.Margins(50, 50, 100, 100);
form.ShowDialog();
See Also