Topics   All   Mac OS X (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server (Not)   Client   Old   Guides   Examples
New in version: 6.3   6.4   6.5   7.0   7.1   7.2   7.3   7.4   7.5   7.6    Statistic  

XL.Sheet.SetProtectEx

Protects/unprotects the sheet with password and enhanced parameters below.

Component Version macOS Windows Server FileMaker Cloud FileMaker iOS SDK
XL 7.2 Yes Yes Yes Yes Yes

MBS( "XL.Sheet.SetProtectEx"; bookRef; sheetIndex; protect; Password; ProtectEx )

Parameters

Parameter Description Example value
bookRef The reference to the workbook. Please use XL.LoadBook to load a file. $ref
sheetIndex The index of the sheet. This number ranges from 0 to XL.Book.SheetCount-1. 0
protect Whether to protect.
Pass 1 to enable protection and 0 to disable.
1
Password The password to use.
ProtectEx The new protection setting.
This can be a list of several options or a number.
"default"

Result

Returns OK or error.

Description

Protects/unprotects the sheet with password and enhanced parameters below.
It is possible to combine a few Enhanced Protection values.

Enhanced Protection valueDescription
defaultDefault protection.
allNothing is allowed except cell selections.
ObjectsObjects are locked when the sheet is protected.
ScenariosScenarios are locked when the sheet is protected.
FormatCellsFormatting cells is allowed when the sheet is protected.
FormatColumnsFormatting columns is allowed when the sheet is protected.
FormatRowsFormatting rows is allowed when the sheet is protected.
InsertColumnsInserting columns is allowed when the sheet is protected.
InsertRowsInserting rows is allowed when the sheet is protected.
InsertHyperlinksInserting hyperlinks is allowed when the sheet is protected.
DeleteColumnsDeleting columns is allowed when the sheet is protected.
DeleteRowsDeleting rows is allowed when the sheet is protected.
SelLockedCellsSelection of locked cells is locked when the sheet is protected.
SortSorting is allowed when the sheet is protected.
AutoFilterAutofilters are allowed when the sheet is protected.
PivotTablesPivot tables are allowed when the sheet is protected.
SelUnlockedCellsSelection of unlocked cells is locked when the sheet is protected.

See also


XL.Sheet.SetProtect   -   XL.Sheet.SetRightToLeft

Feedback: Report problem or ask question.




Links
MBS Xojo blog