HotXLS 문서

보호 권한 속성

이러한 Boolean 속성들은 보호된 기존 XLS 워크시트의 BIFF8 SheetProtect 레코드에 저장된 작업별 권한을 제어합니다. 통합 문서를 저장하기 전에 설정하고, 워크시트 보호를 활성화하려면 Protect를 호출합니다

구문

property AllowEditObjects: Boolean;
property AllowEditScenarios: Boolean;
property AllowFormatCells: Boolean;
property AllowFormatColumns: Boolean;
property AllowFormatRows: Boolean;
property AllowInsertColumns: Boolean;
property AllowInsertRows: Boolean;
property AllowInsertHyperlinks: Boolean;
property AllowDeleteColumns: Boolean;
property AllowDeleteRows: Boolean;
property AllowSelectLockedCells: Boolean;
property AllowSort: Boolean;
property AllowAutoFilter: Boolean;
property AllowPivotTables: Boolean;
property AllowSelectUnlockedCells: Boolean;

기본값

AllowSelectLockedCells 및 AllowSelectUnlockedCells의 기본값은 True이고 다른 권한 속성의 기본값은 False입니다

예제

Sheet.AllowDeleteRows := True;
Sheet.AllowInsertRows := True;
Sheet.AllowAutoFilter := True;
Sheet.Protect('mypass123');

참조