java.lang.Object
com.aspose.cells.WorkbookSettings
public class WorkbookSettings
Example:
Workbook workbook = new Workbook();
WorkbookSettings settings = workbook.getSettings();
//do your business
| Property Getters/Setters Summary | ||
|---|---|---|
java.lang.String | getAuthor() | |
void | setAuthor(java.lang.String) | |
| Gets and sets the author of the file. | ||
boolean | getAutoCompressPictures() | |
void | setAutoCompressPictures(boolean) | |
| Specifies a boolean value that indicates the application automatically compressed pictures in the workbook. | ||
boolean | getAutoRecover() | |
void | setAutoRecover(boolean) | |
| Indicates whether the file is mark for auto-recovery. | ||
java.lang.String | getBuildVersion() | |
void | setBuildVersion(java.lang.String) | |
| Specifies the incremental public release of the application. | ||
int | getCalcMode() | |
void | setCalcMode(int) | |
| It specifies whether to calculate formulas manually, automatically or automatically except for multiple table operations. The value of the property is CalcModeType integer constant. | ||
int | getCalcStackSize() | |
void | setCalcStackSize(int) | |
| Specifies the stack size for calculating cells recursively. The large value for this size will give better performance when there are lots of cells need to be calculated recursively. On the other hand, larger value will raise the risk of StackOverflowException. If user gets StackOverflowException when calculating formulas, this value should be decreased. | ||
java.lang.String | getCalculationId() | |
void | setCalculationId(java.lang.String) | |
| Specifies the version of the calculation engine used to calculate values in the workbook. | ||
boolean | getCheckCompatibility() | |
void | setCheckCompatibility(boolean) | |
| Indicates whether check compatibility with earlier versions when saving workbook. | ||
boolean | getCheckCustomNumberFormat() | |
void | setCheckCustomNumberFormat(boolean) | |
| Indicates whether checking custom number format when setting Style.Custom. | ||
boolean | getCheckExcelRestriction() | |
void | setCheckExcelRestriction(boolean) | |
| Whether check restriction of excel file when user modify cells related objects. For example, excel does not allow inputting string value longer than 32K. When you input a value longer than 32K such as by Cell.PutValue(string), if this property is true, you will get an Exception. If this property is false, we will accept your input string value as the cell's value so that later you can output the complete string value for other file formats such as CSV. However, if you have set such kind of value that is invalid for excel file format, you should not save the workbook as excel file format later. Otherwise there may be unexpected error for the generated excel file. | ||
int | getCompliance() | |
void | setCompliance(int) | |
| Specifies the OOXML version for the output document. The default value is Ecma376_2006. The value of the property is OoxmlCompliance integer constant. | ||
boolean | getCrashSave() | |
void | setCrashSave(boolean) | |
| indicates whether the application last saved the workbook file after a crash. | ||
boolean | getCreateCalcChain() | |
void | setCreateCalcChain(boolean) | |
| Whether creates calculated formulas chain. Default is false. | ||
boolean | getDataExtractLoad() | |
void | setDataExtractLoad(boolean) | |
| indicates whether the application last opened the workbook for data recovery. | ||
boolean | getDate1904() | |
void | setDate1904(boolean) | |
| Gets or sets a value which represents if the workbook uses the 1904 date system. | ||
int | getDisplayDrawingObjects() | |
void | setDisplayDrawingObjects(int) | |
| Indicates whether and how to show objects in the workbook. The value of the property is DisplayDrawingObjects integer constant. | ||
boolean | getEnableMacros() | |
void | setEnableMacros(boolean) | |
| Enable macros; | ||
int | getFirstVisibleTab() | |
void | setFirstVisibleTab(int) | |
| Gets or sets the first visible worksheet tab. | ||
boolean | getForceFullCalculate() | |
void | setForceFullCalculate(boolean) | |
| Fully calculates every time when a calculation is triggered. | ||
FormulaSettings | getFormulaSettings() | |
| Gets the settings for formula-related features. | ||
GlobalizationSettings | getGlobalizationSettings() | |
void | setGlobalizationSettings(GlobalizationSettings) | |
| Gets and sets the globalization settings. | ||
boolean | getHidePivotFieldList() | |
void | setHidePivotFieldList(boolean) | |
| Gets and sets whether hide the field list for the PivotTable. | ||
boolean | isDefaultEncrypted() | |
void | setDefaultEncrypted(boolean) | |
| Indicates whether encrypting the workbook with default password if Structure and Windows of the workbook are locked. | ||
boolean | isEncrypted() | |
| Gets a value that indicates whether a password is required to open this workbook. | ||
boolean | isHidden() | |
void | setHidden(boolean) | |
| Indicates whether this workbook is hidden. | ||
boolean | isHScrollBarVisible() | |
void | setHScrollBarVisible(boolean) | |
| Gets or sets a value indicating whether the generated spreadsheet will contain a horizontal scroll bar. | ||
boolean | isMinimized() | |
void | setMinimized(boolean) | |
| Represents whether the generated spreadsheet will be opened Minimized. | ||
boolean | isProtected() | |
| Gets a value that indicates whether the structure or window of the Workbook is protected. | ||
boolean | isVScrollBarVisible() | |
void | setVScrollBarVisible(boolean) | |
| Gets or sets a value indicating whether the generated spreadsheet will contain a vertical scroll bar. | ||
boolean | getIteration() | |
void | setIteration(boolean) | |
| Indicates whether enable iterative calculation to resolve circular references. | ||
int | getLanguageCode() | |
void | setLanguageCode(int) | |
| Gets or sets the user interface language of the Workbook version based on CountryCode that has saved the file. The value of the property is CountryCode integer constant. | ||
java.util.Locale | getLocale() | |
void | setLocale(java.util.Locale) | |
| Gets or sets the Locale used by this workbook. | ||
double | getMaxChange() | |
void | setMaxChange(double) | |
| Returns or sets the maximum number of change to resolve a circular reference. | ||
int | getMaxColumn() | |
| Gets the max column index, zero-based. | ||
int | getMaxIteration() | |
void | setMaxIteration(int) | |
| Returns or sets the maximum number of iterations to resolve a circular reference. | ||
int | getMaxRow() | |
| Gets the max row index, zero-based. | ||
int | getMaxRowsOfSharedFormula() | |
void | setMaxRowsOfSharedFormula(int) | |
| Gets and sets the max row number of shared formula. | ||
int | getMemorySetting() | |
void | setMemorySetting(int) | |
| Gets or sets the memory usage options. The new option will be taken as the default option for newly created worksheets but does not take effect for existing worksheets. The value of the property is MemorySetting integer constant. | ||
char | getNumberDecimalSeparator() | |
void | setNumberDecimalSeparator(char) | |
| Gets or sets the decimal separator for formatting/parsing numeric values. Default is the decimal separator of current Region. | ||
char | getNumberGroupSeparator() | |
void | setNumberGroupSeparator(char) | |
| Gets or sets the character that separates groups of digits to the left of the decimal in numeric values. Default is the group separator of current Region. | ||
int | getPaperSize() | |
void | setPaperSize(int) | |
| Gets and sets the default print paper size. The value of the property is PaperSizeType integer constant. | ||
boolean | getParsingFormulaOnOpen() | |
void | setParsingFormulaOnOpen(boolean) | |
| Indicates whether parsing the formula when reading the file. | ||
java.lang.String | getPassword() | |
void | setPassword(java.lang.String) | |
| Represents Workbook file encryption password. | ||
boolean | getPrecisionAsDisplayed() | |
void | setPrecisionAsDisplayed(boolean) | |
| True if calculations in this workbook will be done using only the precision of the numbers as they're displayed | ||
int | getProtectionType() | |
| Gets the protection type of the workbook. The value of the property is ProtectionType integer constant. | ||
boolean | getQuotePrefixToStyle() | |
void | setQuotePrefixToStyle(boolean) | |
|
Indicates whether setting |
||
boolean | getRecalculateBeforeSave() | |
void | setRecalculateBeforeSave(boolean) | |
| Indicates whether to recalculate before saving the document. | ||
boolean | getReCalculateOnOpen() | |
void | setReCalculateOnOpen(boolean) | |
| Indicates whether re-calculate all formulas on opening file. | ||
int | getRegion() | |
void | setRegion(int) | |
| Gets or sets the regional settings for workbook. The value of the property is CountryCode integer constant. | ||
boolean | getRemovePersonalInformation() | |
void | setRemovePersonalInformation(boolean) | |
| True if personal information can be removed from the specified workbook. | ||
boolean | getRepairLoad() | |
void | setRepairLoad(boolean) | |
| Indicates whether the application last opened the workbook in safe or repair mode. | ||
IStreamProvider | getResourceProvider() | |
void | setResourceProvider(IStreamProvider) | |
| Gets and sets the stream provider for external resource, such as loading image data for picture of type "LinkToFile". | ||
boolean | getShared() | |
void | setShared(boolean) | |
| Gets or sets a value that indicates whether the Workbook is shared. | ||
int | getSheetTabBarWidth() | |
void | setSheetTabBarWidth(int) | |
| Width of worksheet tab bar (in 1/1000 of window width). | ||
boolean | getShowTabs() | |
void | setShowTabs(boolean) | |
| Get or sets a value whether the Workbook tabs are displayed. | ||
int | getSignificantDigits() | |
void | setSignificantDigits(int) | |
|
Gets and sets the number of significant digits.
The default value is |
||
IStreamProvider | getStreamProvider() | |
void | setStreamProvider(IStreamProvider) | |
| Gets and sets the stream provider for external resource. | ||
boolean | getUpdateAdjacentCellsBorder() | |
void | setUpdateAdjacentCellsBorder(boolean) | |
| Indicates whether update adjacent cells' border. | ||
int | getUpdateLinksType() | |
void | setUpdateLinksType(int) | |
| Gets and sets how updates external links when the workbook is opened. The value of the property is UpdateLinksType integer constant. | ||
IWarningCallback | getWarningCallback() | |
void | setWarningCallback(IWarningCallback) | |
| Gets or sets warning callback. | ||
double | getWindowHeight() | |
void | setWindowHeight(double) | |
| The height of the window, in unit of point. | ||
double | getWindowHeightCM() | |
void | setWindowHeightCM(double) | |
| The height of the window, in unit of centimeter. | ||
double | getWindowHeightInch() | |
void | setWindowHeightInch(double) | |
| The height of the window, in unit of inch. | ||
double | getWindowLeft() | |
void | setWindowLeft(double) | |
| The distance from the left edge of the client area to the left edge of the window, in unit of point. | ||
double | getWindowLeftCM() | |
void | setWindowLeftCM(double) | |
| The distance from the left edge of the client area to the left edge of the window. In unit of centimeter. | ||
double | getWindowLeftInch() | |
void | setWindowLeftInch(double) | |
| The distance from the left edge of the client area to the left edge of the window. In unit of inch. | ||
double | getWindowTop() | |
void | setWindowTop(double) | |
| The distance from the top edge of the client area to the top edge of the window, in unit of point. | ||
double | getWindowTopCM() | |
void | setWindowTopCM(double) | |
| The distance from the top edge of the client area to the top edge of the window, in unit of centimeter. | ||
double | getWindowTopInch() | |
void | setWindowTopInch(double) | |
| The distance from the top edge of the client area to the top edge of the window, in unit of inch. | ||
double | getWindowWidth() | |
void | setWindowWidth(double) | |
| The width of the window, in unit of point. | ||
double | getWindowWidthCM() | |
void | setWindowWidthCM(double) | |
| The width of the window, in unit of centimeter. | ||
double | getWindowWidthInch() | |
void | setWindowWidthInch(double) | |
| The width of the window, in unit of inch. | ||
WriteProtection | getWriteProtection() | |
| Provides access to the workbook write protection options. | ||
| Method Summary | ||
|---|---|---|
void | dispose() | |
| Releases resources. | ||
java.lang.String | getThemeFont(int type) | |
| Gets the default theme font name. | ||
void | setPageOrientationType(int pageOrientationType) | |
| Set the type of print orientation for the whole workbook. | ||
| Property Getters/Setters Detail |
|---|
getStreamProvider/setStreamProvider | |
public IStreamProvider getStreamProvider() / public void setStreamProvider(IStreamProvider value) | |
getResourceProvider/setResourceProvider | |
public IStreamProvider getResourceProvider() / public void setResourceProvider(IStreamProvider value) | |
getAuthor/setAuthor | |
public java.lang.String getAuthor() / public void setAuthor(java.lang.String value) | |
getCheckCustomNumberFormat/setCheckCustomNumberFormat | |
public boolean getCheckCustomNumberFormat() / public void setCheckCustomNumberFormat(boolean value) | |
getEnableMacros/setEnableMacros | |
public boolean getEnableMacros() / public void setEnableMacros(boolean value) | |
getDate1904/setDate1904 | |
public boolean getDate1904() / public void setDate1904(boolean value) | |
getProtectionType | |
public int getProtectionType() | |
getDisplayDrawingObjects/setDisplayDrawingObjects | |
public int getDisplayDrawingObjects() / public void setDisplayDrawingObjects(int value) | |
getSheetTabBarWidth/setSheetTabBarWidth | |
public int getSheetTabBarWidth() / public void setSheetTabBarWidth(int value) | |
getShowTabs/setShowTabs | |
public boolean getShowTabs() / public void setShowTabs(boolean value) | |
Example:
// Hide the spreadsheet tabs. workbook.getSettings().setShowTabs(false);
getFirstVisibleTab/setFirstVisibleTab | |
public int getFirstVisibleTab() / public void setFirstVisibleTab(int value) | |
isHScrollBarVisible/setHScrollBarVisible | |
public boolean isHScrollBarVisible() / public void setHScrollBarVisible(boolean value) | |
Example:
// Hide the horizontal scroll bar of the Excel file. settings.setHScrollBarVisible(false);
isVScrollBarVisible/setVScrollBarVisible | |
public boolean isVScrollBarVisible() / public void setVScrollBarVisible(boolean value) | |
Example:
// Hide the vertical scroll bar of the Excel file. settings.setVScrollBarVisible(false);
getShared/setShared | |
public boolean getShared() / public void setShared(boolean value) | |
getLanguageCode/setLanguageCode | |
public int getLanguageCode() / public void setLanguageCode(int value) | |
getRegion/setRegion | |
public int getRegion() / public void setRegion(int value) | |
getLocale/setLocale | |
public java.util.Locale getLocale() / public void setLocale(java.util.Locale value) | |
getGlobalizationSettings/setGlobalizationSettings | |
public GlobalizationSettings getGlobalizationSettings() / public void setGlobalizationSettings(GlobalizationSettings value) | |
getNumberDecimalSeparator/setNumberDecimalSeparator | |
public char getNumberDecimalSeparator() / public void setNumberDecimalSeparator(char value) | |
getNumberGroupSeparator/setNumberGroupSeparator | |
public char getNumberGroupSeparator() / public void setNumberGroupSeparator(char value) | |
getPassword/setPassword | |
public java.lang.String getPassword() / public void setPassword(java.lang.String value) | |
getWriteProtection | |
public WriteProtection getWriteProtection() | |
isEncrypted | |
public boolean isEncrypted() | |
isProtected | |
public boolean isProtected() | |
isDefaultEncrypted/setDefaultEncrypted | |
public boolean isDefaultEncrypted() / public void setDefaultEncrypted(boolean value) | |
isMinimized/setMinimized | |
public boolean isMinimized() / public void setMinimized(boolean value) | |
isHidden/setHidden | |
public boolean isHidden() / public void setHidden(boolean value) | |
getAutoCompressPictures/setAutoCompressPictures | |
public boolean getAutoCompressPictures() / public void setAutoCompressPictures(boolean value) | |
getRemovePersonalInformation/setRemovePersonalInformation | |
public boolean getRemovePersonalInformation() / public void setRemovePersonalInformation(boolean value) | |
getHidePivotFieldList/setHidePivotFieldList | |
public boolean getHidePivotFieldList() / public void setHidePivotFieldList(boolean value) | |
getUpdateLinksType/setUpdateLinksType | |
public int getUpdateLinksType() / public void setUpdateLinksType(int value) | |
getMaxRow | |
public int getMaxRow() | |
getMaxColumn | |
public int getMaxColumn() | |
getParsingFormulaOnOpen/setParsingFormulaOnOpen | |
public boolean getParsingFormulaOnOpen() / public void setParsingFormulaOnOpen(boolean value) | |
getWindowLeft/setWindowLeft | |
public double getWindowLeft() / public void setWindowLeft(double value) | |
getWindowLeftInch/setWindowLeftInch | |
public double getWindowLeftInch() / public void setWindowLeftInch(double value) | |
getWindowLeftCM/setWindowLeftCM | |
public double getWindowLeftCM() / public void setWindowLeftCM(double value) | |
getWindowTop/setWindowTop | |
public double getWindowTop() / public void setWindowTop(double value) | |
getWindowTopInch/setWindowTopInch | |
public double getWindowTopInch() / public void setWindowTopInch(double value) | |
getWindowTopCM/setWindowTopCM | |
public double getWindowTopCM() / public void setWindowTopCM(double value) | |
getWindowWidth/setWindowWidth | |
public double getWindowWidth() / public void setWindowWidth(double value) | |
getWindowWidthInch/setWindowWidthInch | |
public double getWindowWidthInch() / public void setWindowWidthInch(double value) | |
getWindowWidthCM/setWindowWidthCM | |
public double getWindowWidthCM() / public void setWindowWidthCM(double value) | |
getWindowHeight/setWindowHeight | |
public double getWindowHeight() / public void setWindowHeight(double value) | |
getWindowHeightInch/setWindowHeightInch | |
public double getWindowHeightInch() / public void setWindowHeightInch(double value) | |
getWindowHeightCM/setWindowHeightCM | |
public double getWindowHeightCM() / public void setWindowHeightCM(double value) | |
getUpdateAdjacentCellsBorder/setUpdateAdjacentCellsBorder | |
public boolean getUpdateAdjacentCellsBorder() / public void setUpdateAdjacentCellsBorder(boolean value) | |
getSignificantDigits/setSignificantDigits | |
public int getSignificantDigits() / public void setSignificantDigits(int value) | |
getCheckCompatibility/setCheckCompatibility | |
public boolean getCheckCompatibility() / public void setCheckCompatibility(boolean value) | |
getCheckExcelRestriction/setCheckExcelRestriction | |
public boolean getCheckExcelRestriction() / public void setCheckExcelRestriction(boolean value) | |
getAutoRecover/setAutoRecover | |
public boolean getAutoRecover() / public void setAutoRecover(boolean value) | |
getCrashSave/setCrashSave | |
public boolean getCrashSave() / public void setCrashSave(boolean value) | |
getDataExtractLoad/setDataExtractLoad | |
public boolean getDataExtractLoad() / public void setDataExtractLoad(boolean value) | |
getRepairLoad/setRepairLoad | |
public boolean getRepairLoad() / public void setRepairLoad(boolean value) | |
getBuildVersion/setBuildVersion | |
public java.lang.String getBuildVersion() / public void setBuildVersion(java.lang.String value) | |
getMemorySetting/setMemorySetting | |
public int getMemorySetting() / public void setMemorySetting(int value) | |
getPaperSize/setPaperSize | |
public int getPaperSize() / public void setPaperSize(int value) | |
getWarningCallback/setWarningCallback | |
public IWarningCallback getWarningCallback() / public void setWarningCallback(IWarningCallback value) | |
getMaxRowsOfSharedFormula/setMaxRowsOfSharedFormula | |
public int getMaxRowsOfSharedFormula() / public void setMaxRowsOfSharedFormula(int value) | |
getCompliance/setCompliance | |
public int getCompliance() / public void setCompliance(int value) | |
getQuotePrefixToStyle/setQuotePrefixToStyle | |
public boolean getQuotePrefixToStyle() / public void setQuotePrefixToStyle(boolean value) | |
getFormulaSettings | |
public FormulaSettings getFormulaSettings() | |
getPrecisionAsDisplayed/setPrecisionAsDisplayed | |
public boolean getPrecisionAsDisplayed() / public void setPrecisionAsDisplayed(boolean value) | |
getReCalculateOnOpen/setReCalculateOnOpen | |
public boolean getReCalculateOnOpen() / public void setReCalculateOnOpen(boolean value) | |
getCreateCalcChain/setCreateCalcChain | |
public boolean getCreateCalcChain() / public void setCreateCalcChain(boolean value) | |
getForceFullCalculate/setForceFullCalculate | |
public boolean getForceFullCalculate() / public void setForceFullCalculate(boolean value) | |
getIteration/setIteration | |
public boolean getIteration() / public void setIteration(boolean value) | |
getMaxIteration/setMaxIteration | |
public int getMaxIteration() / public void setMaxIteration(int value) | |
getMaxChange/setMaxChange | |
public double getMaxChange() / public void setMaxChange(double value) | |
getCalcMode/setCalcMode | |
public int getCalcMode() / public void setCalcMode(int value) | |
getCalculationId/setCalculationId | |
public java.lang.String getCalculationId() / public void setCalculationId(java.lang.String value) | |
getCalcStackSize/setCalcStackSize | |
public int getCalcStackSize() / public void setCalcStackSize(int value) | |
getRecalculateBeforeSave/setRecalculateBeforeSave | |
public boolean getRecalculateBeforeSave() / public void setRecalculateBeforeSave(boolean value) | |
| Method Detail |
|---|
dispose | |
public void dispose() | |
getThemeFont | |
public java.lang.String getThemeFont(int type) | |
type - A setPageOrientationType | |
public void setPageOrientationType(int pageOrientationType) | |
pageOrientationType - A