Gets or sets the section's page size. The width and height are always the values in portrait orientation.

Syntax

public System.Drawing.Size PageSize { get; set; }
Public Property PageSize() As System.Drawing.Size

Examples

The following example uses PageSize property to set the width and height of the section's page as (500, 1000).

TXTextControl.SectionFormat sf = new TXTextControl.SectionFormat(3, new int[] { 1500, 2500, 5000 }, new int[] { 250, 500 });

sf.ColumnLineColor = Color.Black;
sf.ColumnLineWidth = 50;
sf.PageSize        = new TXTextControl.PageSize(500, 1000);
sf.Landscape       = true;
sf.PageMargins     = new TXTextControl.PageMargins(100, 100, 100, 100);

textControl1.Sections.Add(TXTextControl.SectionBreakKind.BeginAtNewPage);

textControl1.Sections.GetItem().Format = sf;
Dim sf As New TXTextControl.SectionFormat(3, New Integer() {1500, 2500, 5000}, New Integer() {250, 500})

sf.ColumnLineColor = Color.Black
sf.ColumnLineWidth = 50
sf.PageSize        = New TXTextControl.PageSize(500, 1000)
sf.Landscape       = True
sf.PageMargins     = New TXTextControl.PageMargins(100,100,100, 100)

TextControl1.Sections.Add(TXTextControl.SectionBreakKind.BeginAtNewPage)

TextControl1.Sections.GetItem().Format = sf

Remarks

The property returns a width and a height of zero when the text selection contains multiple sections with mixed sizes. The Selection.IsCommonValueSelected method can be used to check for mixed attributes.