Skip to main content
Skip table of contents

Call class page function from element Event

You can Edit page class to add your custom functions.

To call these function in an element Event, for example, you may:

_ Add an attribute, for example (contextmenu) in the element and directly call the function:

CODE
this['my_custom_function']()
or
my_custom_function()

_ Add an Event component to the Element and fill it with (contextmenu). Add a CustomAction component as a child, call your custom function:

CODE
page['my_custom_function'](params);

You may need to add the following code to prevent default browser behaviour:

CODE
event.preventDefault();
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.