I am trying to implement the beforeedit listener in my table. I would like to do some checking before a user is allowed to do something to the cell.
Ext.define('myGrid', {
extend: 'Ext.grid.Panel',
listeners: {
beforeedit: function (e) {
alert('hi')
},
}
When I try and edit a cell, this alert(..) is not called. Why is this not going into the listener? If I look on the internet there are plenty of examples of Ext.grid.Panel with beforeedit.
Anyway I tried to extend with Ext.grid.EditorGridPanel instead.
Ext.define('myGrid', {
extend: 'Ext.grid.EditorGridPanel',
listeners: {
beforeedit: function (e) {
alert('hi')
}
}
Now I get an obscure error in typical extjs fashion :
What am I doing wrong? And why should you use EditorGridPanel over normal grid? Is it for the Excel like properties?
EDIT : yes. sorry i forgot to put beforeedit in 'listeners'. Question still stands as is though.