Skip to main content
All docs
V25.1
  • How to: Insert Page Breaks in a Worksheet

    A worksheet’s page breaks are stored in two PageBreaksCollection collections:

    Use the PageBreaksCollection.Add method to insert page breaks.

    // Insert a page break after the "F" column.
    worksheet.VerticalPageBreaks.Add(6);
    // Insert a page break below the 14th row.
    worksheet.HorizontalPageBreaks.Add(14);
    

    Delete a Page Break

    Use the following API to remove page breaks from a worksheet: