TextStyleHandler oTextStyleSupplier = new TextStyleHandler(xMSFDoc, xTextDocument);
Helper.setUnoPropertyValue(xTextDocument, "ApplyFormDesignMode", Boolean.FALSE);
oViewHandler.setViewSetting("ShowTableBoundaries", Boolean.FALSE);
oViewHandler.setViewSetting("ShowOnlineLayout", Boolean.TRUE);
xPropPageStyle = oTextStyleSupplier.getStyleByName("PageStyles", "Standard");
Size aSize = oTextStyleHandler.changePageAlignment(xPropPageStyle, true);
nPageWidth = aSize.Width;
nPageHeight = aSize.Height;
sMsgEndAutopilot = oResource.getResText(UIConsts.RID_DB_COMMON + 33);
} catch (Exception e) {
e.printStackTrace(System.out);