[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.IWorkbook.Unprotect

Unprotect Method

Unprotect(string)

Removes protection from the workbook.

Use this method to remove protection that was applied with Protect(string, bool, bool) or another non-password overload of protect. If the workbook was protected with a password, use Unprotect(string) with the correct password instead.

Declaration
void Unprotect(string password = null)
Sub Unprotect(Optional password As String = Nothing)
Parameters
Type Name Description
string password

The password used to remove protection, or null to remove protection that was applied without a password.

Examples
worksheet.Range["A1"].Value = "Confidential";
workbook.Protect();
workbook.Unprotect();