Dokumentacija HotXLS

Protect metoda

Protects a Worksheet so that it cannot be modified

Sintaksa

procedure Protect();
procedure Protect(Password: string);
Password String. A string that specifies a case-sensitive password for the Worksheet. If this argument is omitted, you can unprotect the Worksheet without using a password. Otherwise, you must specify the password to unprotect the Worksheet

Primjer

This example protects Worksheet one

Workbook.Sheets[1].Protect('mypass123');

Vidi također