IWxObject.Protection

Syntax

Protection(ObjectProperty: WxObjectProperty): Boolean;

Parameters

ObjectProperty determines the protected property.

Description

The Protection property prevents object properties from being changed. If this property is set to True, the property specified as a parameter is protected from changes.

The default property value is False.

Example

Executing the example requires an existing ws object of the IWxWorkspace type.

Sub UserProc;

Var

ws: IWxWorkspace;

Shape: IWxShape;

Begin

Shape := ws.Shapes.Item(0);

Shape.Protection(WxObjectProperty.EntityFree):= False;

End Sub UserProc;

After executing the example deletion of an object located in a workspace is disabled.

See also:

IWxObject