Event Handling

Attaching event listeners

You can attach event listeners with the dhxPopup.events.on() method:

dhxPopup.events.on("Click", function(e){
    console.log("The popup was clicked");
});

The names of events are case-insensitive.

Detaching event listeners

To detach events, use dhxPopup.events.detach():

dhxPopup.events.on("Click", function(e){
    console.log("The popup was clicked");
});
 
dhxPopup.events.detach("Click");

Calling events

To call events, use dhxPopup.events.fire():

dhxPopup.events.fire("name",args);
// where args is an array of arguments

The list of events

The full list of events is available in the related API section.

Back to top