# NOT RUN {
wb <- createWorkbook()
addWorksheet(wb, "Sheet 1")
writeData(wb, sheet = 1, x = iris)
pageBreak(wb, sheet = 1, i = 10, type = "row")
pageBreak(wb, sheet = 1, i = 20, type = "row")
pageBreak(wb, sheet = 1, i = 2, type = "column")
# }
# NOT RUN {
saveWorkbook(wb, "pageBreakExample.xlsx", TRUE)
# }
# NOT RUN {
## In Excel: View tab -> Page Break Preview
# }
Run the code above in your browser using DataLab