Skip to content

excel pagebreak

goworm edited this page Jun 26, 2026 · 1 revision

Excel: Page Break

Manual row and column page breaks on a worksheet — a dispatcher that routes to a row break or a column break depending on whether you supply row or col/column.

Path: /{SheetName}/rowbreak[N] or /{SheetName}/colbreak[N]

Operations

  • add - Insert a manual row or column page break
  • set, get, query, remove - Standard operations

add

Parent: /{SheetName}

Supply either row (routes to a row break) or col/column (routes to a column break).

Properties

Property Required Description
row Row index — routes to a row break. Add-time only (Set is not supported; re-add to relocate).
col (alias column) Column index/letter — routes to a column break. Add-time only (Set is not supported; re-add to relocate).

Examples

# Insert a horizontal page break before row 20
officecli add data.xlsx /Sheet1 --type pagebreak --prop row=20

# Insert a vertical page break before column F
officecli add data.xlsx /Sheet1 --type pagebreak --prop col=F

# column is an accepted alias for col
officecli add data.xlsx /Sheet1 --type pagebreak --prop column=F

# Query all page breaks
officecli query data.xlsx pagebreak

# Remove a row break by index
officecli remove data.xlsx /Sheet1/rowbreak[1]

Notes

  • This is a dispatcher element: supplying row resolves to a row break, while supplying col/column resolves to a column break.
  • row and col are add-time only — Set is not supported. To relocate a break, re-add it.
  • These properties are not surfaced back on get. Use sheet.rowBreaks and sheet.colBreaks for the indexed lists of breaks on a sheet.

See Also


Based on OfficeCLI v1.0.119

Clone this wiki locally