[]
ICustomView 记录创建自定义视图时捕获的工作簿视图状态。getName() 方法标识自定义视图。getRowColSettings() 表示是否包含隐藏的行和列以及筛选信息,getPrintSettings() 表示是否包含打印设置。可以通过 Workbook.getCustomViews() 创建自定义视图,使用 show() 应用自定义视图,并使用 delete() 移除自定义视图。
ICustomView customView = workbook.getCustomViews().add("ReviewView", true, true);
String name = customView.getName();
customView.show();
voiddelete()ICustomViews 集合中删除此自定义视图。getName()booleanbooleanvoidshow()此方法返回创建 ICustomView 时分配给它的名称。
ICustomView customView = workbook.getCustomViews().add("ReviewView", true, true);
String name = customView.getName();
此属性指示行和列的可见性设置是否与自定义视图一起存储。
ICustomView customView = workbook.getCustomViews().add("HiddenRows", false, true);
boolean includeRowColSettings = customView.getRowColSettings();
true;否则为 false。此属性反映创建自定义视图时指定的 printSettings 选项。
ICustomView customView = workbook.getCustomViews().add("PrintView", true, false);
boolean includePrintSettings = customView.getPrintSettings();
true;否则为 false。使用此方法可以将工作簿切换到此自定义视图中存储的状态,包括创建自定义视图时捕获的视图设置。
ICustomView customView = workbook.getCustomViews().add("PrintView", true, false);
customView.show();
ICustomViews 集合中删除此自定义视图。调用此方法后,该自定义视图将从工作簿的自定义视图集合中移除。
ICustomView customView = workbook.getCustomViews().add("ReviewView", true, true);
customView.delete();