PageSetup

Overview

PageSetup is a class in Aspose.Cells for NET.

PageSetup.AddHorizontalPageBreak adds a page break after the specified row index.

Properties

NameTypeAccessDescription
PaperSizePaperSizeTypeRead/WriteGets or sets the paper size used for printing
OrientationPageOrientationTypeRead/WriteGets or sets the page orientation (portrait or landscape)
FirstPageNumberint?Read/WriteGets or sets the number printed on the first page, nullable
Scaleint?Read/WriteGets or sets the print scaling percentage, nullable
FitToPagesWideint?Read/WriteGets or sets the number of pages wide to fit when printing, nullable
FitToPagesTallint?Read/Write
PrintAreastringRead/WriteGets or sets the cell range that will be printed
PrintTitleRowsstringRead/WriteGets or sets rows repeated at the top of each printed page
PrintTitleColumnsstringRead/WriteGets or sets columns repeated at the left of each printed page
LeftMargindoubleRead/WriteGets or sets the left margin in points
RightMargindoubleRead/WriteGets or sets the right margin in points
TopMargindoubleRead/WriteGets or sets the top margin in points
BottomMargindoubleRead/WriteGets or sets the bottom margin in points
HeaderMargindoubleRead/WriteGets or sets the header margin in points
FooterMargindoubleRead/WriteGets or sets the footer margin in points
LeftMarginInchdoubleRead/WriteGets or sets the left margin in inches
RightMarginInchdoubleRead/WriteGets or sets the right margin in inches
TopMarginInchdoubleRead/WriteGets or sets the top margin in inches
BottomMarginInchdoubleRead/WriteGets or sets the bottom margin in inches
HeaderMarginInchdoubleRead/WriteGets or sets the header margin in inches
FooterMarginInchdoubleRead/WriteGets or sets the footer margin in inches
LeftHeaderstringRead/WriteGets or sets the text displayed in the left section of the header
CenterHeaderstringRead/Write
RightHeaderstringRead/WriteGets or sets text displayed in the right section of the page header
LeftFooterstringRead/WriteGets or sets text displayed in the left section of the page footer
CenterFooterstringRead/WriteGets or sets the text displayed in the center section of the footer
RightFooterstringRead/Write
PrintGridlinesboolRead/WriteGets or sets whether gridlines are printed on the page
PrintHeadingsboolRead/WriteGets or sets whether row and column headings are printed
CenterHorizontallyboolRead/WriteGets or sets whether the sheet is centered horizontally when printed
CenterVerticallyboolRead/Write
HorizontalPageBreaksIReadOnlyList<int>Read
VerticalPageBreaksIReadOnlyList<int>Read

Methods

SignatureDescription
AddHorizontalPageBreak(rowIndex: int)Adds a page break after the specified row index
AddVerticalPageBreak(columnIndex: int)Adds a page break after the specified column index
ClearHorizontalPageBreaks()Removes all horizontal page breaks
ClearVerticalPageBreaks()Removes all vertical page breaks