Click or drag to resize
ExcelPrintOptionsPortrait Property
for portrait orientation, for landscape orientation.

Namespace:  GemBox.Spreadsheet
Assembly:  GemBox.Spreadsheet (in GemBox.Spreadsheet.dll) Version:
public bool Portrait { get; set; }

Property Value

Type: Boolean

Default value for this property is .

This member is supported in printing.

GemBox.Spreadsheet uses enhanced printing services provided with Windows Presentation Foundation (WPF). All pages of a specific ExcelWorksheet will be printed with settings from PrintOptions of that worksheet. Internally, WPF printing uses PrintTicket class to specify page printing settings and value of this member is applied to appropriate member of PrintTicket instance which is used to print all pages of a worksheet with this print options member.

PrintTicket instance which is used to print every page of a worksheet is constructed in following order:

Based on stream specified in PrintOptions(MemoryStream) constructor (base print ticket). Appropriate base print ticket members are set based on PrintOptions instance members values. Base print ticket is cloned for each worksheet, clone's appropriate members are set based on ExcelPrintOptions instance of that worksheet and clone is used to print all pages of that worksheet.

Printing settings which do not exist in PrintOptions nor in ExcelPrintOptions can be specified on base print ticket (which stream is passed to PrintOptions(MemoryStream) constructor).

See Also