Excel has different modes for viewing a sheet: Normal, Page Layout, Page Break Preview. (In excel 2010: in the view tab). The view mode is saved seperately for each sheet in
XSSF doesn't expose this directly, but you can get at it if you want
From the XSSFSheet
object, call getCTWorksheet
to get the low level XML object backing the sheet. CTWorksheet provides a getSheetViews
method. You'll like want something like:
CTSheetView view = sheet.getCTWorksheet().getSheetViews().getSheetViewArray(0);
view.setView(STSheetViewType.PAGE_LAYOUT);