I have a grid that uses startEditByPosition() to set which cell is being edited. When the rows are added I want the first column of the last row to be edited. It works fine until there is not enough space in the grid and there has to be a scroll bar. When a new row is added after the scroll bar is needed, the cell startes to be edited, and then it is canceled. This means that the user will have to click on the cell again to edit it.

This is the code that adds a row to the grid. This is the items array of the gridpanel. topScope is a pointer to the gridpanel. I tried to debug but its very difficult and I haven't found why the edit gets canceled.

items: [{xtype: 'button',
text: 'Add',
handler: function(){
topScope.store.insert(topScope.store.count() , new CheckBreakDownModel()); topScope.rowEditing.startEditByPosition( { row: topScope.store.count() - 1, column: 0 });