I have a button with a handler. In this handler I call for this function:
onAddClick = function() {
gridStore = Ext.getStore('gridEdit');
var rec = new gridStore({
stopCode: '',
stopOrder: '',
stopId: ''
}), edit = this.editing;
edit.cancelEdit();
this.store.insert(0, rec);
edit.startEditByPosition({
row: 0,
column: 1
});
};
When I click on the button it will give the error message: "gridStore is not a constructor". Why is this?