External Interfaces Reference |
Syntax
Description
h.addproperty('propertyname')
adds the custom property specified in the string, propertyname
, to the object or interface, h
. Use set to assign a value to the property.
addproperty(h, 'propertyname')
is an alternate syntax for the same operation.
Examples
Create an mwsamp
control and add a new property named Position
to it. Assign an array value to the property:
f = figure('position', [100 200 200 200]); h = actxcontrol('mwsamp.mwsampctrl.2', [0 0 200 200], f); h.get Label: 'Label' Radius: 20 h.addproperty('Position'); h.Position = [200 120]; h.get Label: 'Label' Radius: 20 Position: [200 120] h.get('Position') ans = 200 120
Delete the custom Position
property:
See Also
deleteproperty
, get
, set
, inspect
actxserver | delete (COM) |
© 1994-2005 The MathWorks, Inc.