Page tree
Skip to end of metadata
Go to start of metadata

Description

Protects the workbook structure using the supplied password. End users will not be able to add or remove worksheets unless they enter the password.

C#
vb.net

Parameters

password
The password to use to protect the workbook. If the password = "" or null, then the workbook will be protected without a password.

Remarks

The equivalent to this action in Excel is to select "Protect structure and windows" from the review menu.

Further protection can be extended to cells by using the Worksheet.Protect() method to protect individual worksheets and by using the Workbook.EncryptPassword property to set a password that must be provided to open the workbook.

Examples

C#
vb.net
  • No labels