Class ExcelProtection
Sets protection on the workbook level ExcelEncryption ExcelSheetProtection
Inherited Members
      System.Object.Equals(System.Object)
    
    
      System.Object.Equals(System.Object, System.Object)
    
    
      System.Object.GetHashCode()
    
    
      System.Object.GetType()
    
    
      System.Object.MemberwiseClone()
    
    
      System.Object.ReferenceEquals(System.Object, System.Object)
    
    
      System.Object.ToString()
    
  Namespace: OfficeOpenXml
Assembly: EPPlus.dll
Syntax
public class ExcelProtection : XmlHelper
  Properties
LockRevision
Lock the workbook for revision
Declaration
public bool LockRevision { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.Boolean | 
LockStructure
Locks the structure,which prevents users from adding or deleting worksheets or from displaying hidden worksheets.
Declaration
public bool LockStructure { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.Boolean | 
LockWindows
Locks the position of the workbook window.
Declaration
public bool LockWindows { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.Boolean | 
WriteProtection
File sharing settings for the workbook.
Declaration
public ExcelWriteProtection WriteProtection { get; }
  Property Value
| Type | Description | 
|---|---|
| ExcelWriteProtection | 
Methods
SetPassword(String)
Sets a password for the workbook. This does not encrypt the workbook.
Declaration
public void SetPassword(string Password)
  Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | Password | The password.  |