类 WriteProtection
java.lang.Object
com.grapecity.documents.excel.WriteProtection
Provides access to the workbook write protection options.
-
构造器概要
-
方法概要
修饰符和类型方法说明boolean
Gets if the Read Only Recommended option is selected.boolean
Gets whether this workbook is write protected.Gets the name of the user who currently has write permission for the workbook.
If you don't explicitly specify this property, the value will come from the IWorkbook.Author, and if the IWorkbook.Author is empty string or null, the value will be "GcExcel".void
setReadOnlyRecommended
(boolean value) Sets if the Read Only Recommended option is selected.void
setWritePassword
(String value) Sets the protected password to modify the file.void
setWriteReservedBy
(String value) Sets the name of the user who currently has write permission for the workbook.boolean
validatePassword
(String password) Returns true if the specified password is the same as the write-protection password the file was protected with.
-
构造器详细资料
-
WriteProtection
public WriteProtection()
-
-
方法详细资料
-
getWriteReservedBy
Gets the name of the user who currently has write permission for the workbook.
If you don't explicitly specify this property, the value will come from the IWorkbook.Author, and if the IWorkbook.Author is empty string or null, the value will be "GcExcel". -
setWriteReservedBy
Sets the name of the user who currently has write permission for the workbook. -
getReadOnlyRecommended
public boolean getReadOnlyRecommended()Gets if the Read Only Recommended option is selected. -
setReadOnlyRecommended
public void setReadOnlyRecommended(boolean value) Sets if the Read Only Recommended option is selected. -
getWriteReserved
public boolean getWriteReserved()Gets whether this workbook is write protected. -
setWritePassword
Sets the protected password to modify the file. -
validatePassword
Returns true if the specified password is the same as the write-protection password the file was protected with.- 参数:
password
- The specified password..
-