Table of contents


on(eventName:String, function:Function|String)

[starting from version: 2.3]

Sets a JS function for the specified event. Check the list of events here.


  • eventName – the name of the component’s event.
  • function – the name of the JS function which will be a handler for the specified component’s event or function itself.


flexmonster.on('celldoubleclick', function () {
  alert('The cell is double clicked');

//If you plan on removing some certain event handler later, 
//add it the following way
flexmonster.on('cellclick', 'onCellClick');
function onCellClick(result) {
  alert('The cell is clicked');

Open the example on JSFiddle.

See also

list of events