Cmdlet
Remove-OfficeExcelPageBreak
Removes manual print page breaks from selected open worksheets.
Syntax
Remove-OfficeExcelPageBreak
[-All]
[-Column <Int32[]>]
[-Document <ExcelDocument>]
[-PassThru]
[-Row <Int32[]>]
[-Sheet <OfficeSheetSelector[]>]
[<CommonParameters>]#Parameter set:
DefaultExamples
Clear manual breaks from report sheets before saving.
Open-OfficeExcel -Path ./Report.xlsx { Remove-OfficeExcelPageBreak -Sheet 'Report*' -All }Parameters
- -All SwitchParameter
- Remove every manual row and column break on the selected worksheets.
- -Column Int32[]
- One-based columns whose manual breaks are removed.
- -Document ExcelDocument
- Gets or sets an explicit live document; omission uses the enclosing content block.
- -PassThru SwitchParameter
- Emit a snapshot for each break actually removed.
- -Row Int32[]
- One-based rows whose manual breaks are removed.
- -Sheet OfficeSheetSelector[]
- Worksheet names, wildcard patterns, one-based positions or native worksheets.
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.
Outputs
PSWriteOffice.Models.Excel.ExcelPageBreakInfo: A manual print page-break snapshot that remains readable after its source workbook is closed.