OBJECT.PROTECTION macro

Changes the protection status of the selected object.

Syntax

OBJECT.PROTECTION(locked, lock_text)

OBJECT.PROTECTION?(locked, lock_text)

Locked    is a logical value that determines whether the selected object is locked or unlocked. If locked is TRUE, Microsoft Excel locks the object; if FALSE, Microsoft Excel unlocks the object.

Lock_text    is a logical value that determines whether text in a text box or button can be changed. Lock_text applies only if the object is a text box, button, or worksheet control. If lock_text is TRUE or omitted, text cannot be changed; if FALSE, text can be changed.

Remarks

 

Related Functions

PROTECT.DOCUMENT   Controls protection for the active worksheet

WORKBOOK.PROTECT   Controls protection for the active workbook

Return to index