This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

deleteproperty

Remove custom property from COM object

Syntax

deleteproperty(c,name)

Description

example

deleteproperty(c,name) deletes property specified by name from custom properties belonging to object or interface c.

You can only delete properties created with the addproperty function.

Examples

collapse all

Create an instance of the control and add custom property Position.

f = figure('position',[100 200 200 200]);
c = actxcontrol('mwsamp.mwsampctrl.2',[0 0 200 200],f);addproperty(h,'Position')
h.Position = [200 120];
get(h)

Add a custom property named Position and assign a value.

addproperty(h,'Position')
h.Position = [200 120];
get(h)
Label: 'Label'
      Radius: 20
    Position: [200 120]

Delete the custom property. MATLAB® displays the original list of properties.

deleteproperty(h,'Position')
get(h)
Label: 'Label'
    Radius: 20

Input Arguments

collapse all

COM object, specified as a function handle.

Property name, specified as a character vector.

Example: 'Position'

Limitations

  • COM functions are available on Microsoft® Windows® systems only.

Introduced before R2006a