TRY NEW VERSION

Try now New API BETA

Try out the new view and capabilities of the API documentation

START

attachContextMenuClickEvent

attachContextMenuClickEvent(id, action)

Defines the method to add an event listener, a function that will be called whenever the specified event is clicked in the context menu.

Parameters:

Name Type Description
id string

The event name.

action function

The event listener.

Returns:

This method doesn't return any data.

Example

Copy code
window.Asc.plugin.attachContextMenuClickEvent("onClickItem1Sub1", function(){
    window.Asc.plugin.executeMethod("InputText", ["clicked: onClickItem1Sub1"]);
});