How to know when a Kendo grid row is in Edit mode

kendo-gridkendo-ui

How to know when a Kendo grid row is in Edit mode without using grid edit event?

var tanquesGrid = $(".tanques").data("kendoGrid");
tanquesGrid.element.delegate("tbody>tr", "dblclick", function () {
       var selectedItem = tanquesGrid.dataItem(tanquesGrid.select());
       if (hasWriteAccess && isClosed == false && selectedItem.EquipmentHistoricID != '')
             tanquesGrid.editRow($(this));
});

The problem is that when row is in inline edit mode and I double click on it, edit mode disappear, this way (code above) I resolve this in new row where the id ! = '' but when edit an existing row the problem persist.

any ideas??

Sorry about my english

Best Answer

          if ( $('#grid').find('.k-grid-edit-row').length ) {
            //grid is not in edit mode          
           } else {
                //grid is in edit mode
                grid.editRow($(this));
            }
Related Topic