Search
CommandEventArgs Class
See Also
 






Specifies data for the rowCommand event.

Namespace: MindFusion.DataViews
File: EventArgs.js

 Syntax

JavaScript  Copy Code

// class
CommandEventArgs.prototype = {}

 Example

The following code handles the rowCommand event of a grid. The event data is provided by the CommandEventArgs class, which derives from RowModifyingEventARgs:

JavaScript  Copy Code
grid.rowCommand.addEventListener(function (sender, args)
{
    if (args.commandName == "Delete")
    {       
         ui.Dialogs.showConfirmDialog("Confirm", "Delete record?", function (result)
         {
             if (result == ui.ModalResult.OK)
             {
                 grid.removeRows(this.row);
             }
         }.bind(args), sender.element, grid.theme);
         args.cancel = true;         
}

 Inheritance Hierarchy

MindFusion.DataViews.CancelEventArgs
    MindFusion.DataViews.RowModifyingEventArgs
        MindFusion.DataViews.CommandEventArgs

 See Also