Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by kunal on Nov 12, 2008 23:09
open dhtmlx forum
problem releted to onEditCell & onCellChanged events

Hello,

I am using dhtmlx grid in my code with custom xml format ie xmlB...
I have used onCellEdit/onCellChanged events in my code...
As per the dhtmlx api, these events should be called when I update the cell
or edit cell... but it is not working as per the api...
Whenever I simply clicked any cell the event gets called...even though I dont update
the cell value or change value of cell,

So please tell me which event should I used which invoked when I really changed the contents of cell..?
Answer posted by Support on Nov 13, 2008 05:09
onCellChanged called when value of cell changed to any other by user or through API
onEditCell called when cell changed by user actions, the first parameter points to current stage of edit process. If you need to catch the final moment of data edit, it can be done as 

mygrid.attachEvent("onEditCell",function(stage,id,ind,old_value,new_value){
    if (stage == 2){
      //here your custom code
    }
    return true;
});