Documentation

This is machine translation

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

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

isevent

Determine whether input is COM object event

Syntax

tf = isevent(c,eventname)

Description

example

tf = isevent(c,eventname) returns logical 1 (true) if eventname is an event recognized by the COM object. Otherwise, it returns logical 0 (false).

Examples

collapse all

Test if DblClick is an event in the MATLAB® sample control. MATLAB displays true, indicating DblClick is an event.

Create an instance of the mwsamp control and test DblClick.

f = figure('position',[100 200 200 200]);
h = actxcontrol('mwsamp.mwsampctrl.2',[0 0 200 200],f);
isevent(h,'DblClick')

Test Redraw. MATLAB displays false, indicating Redraw is not an event; it is a method.

isevent(h,'Redraw')

Input Arguments

collapse all

COM object, specified as a function handle.

Event name, specified as a character vector. The eventname argument is not case-sensitive.

Limitations

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

Introduced before R2006a

Was this topic helpful?