GridOptionsPrint.AllowMultilineHeaders Property

Gets or sets whether text is wrapped in the print/export output if it contains newline characters.

Namespace: DevExpress.XtraGrid.Views.Grid

Assembly: DevExpress.XtraGrid.v21.2.dll

Declaration

[DefaultValue(false)]
[XtraSerializableProperty]
public virtual bool AllowMultilineHeaders { get; set; }

Property Value

Type Default Description
Boolean

false

true if text is wrapped in the print/export output if it contains newline characters; otherwise, false.

Property Paths

You can access this nested property as listed below:

Object Type Path to AllowMultilineHeaders
AdvBandedGridView
.OptionsPrint.AllowMultilineHeaders
BandedGridView
.OptionsPrint.AllowMultilineHeaders
GridView
.OptionsPrint.AllowMultilineHeaders

Remarks

You can include newline characters in column headers and band headers using the “\n” escape sequence in C#, and the VbCrLf constant in Visual Basic. By default, the AllowMultilineHeaders property is set to false and as a result, newline characters are ignored when the grid is printed/exported. For newlines to be in effect in the print/export output, set the AllowMultilineHeaders property to true.

Note

By default, column and band headers are not auto enlarged to fit multi-line text. You can make the header panels bigger using the GridView.ColumnPanelRowHeight and BandedGridView.BandPanelRowHeight properties, respectively.

See Also