Monday, May 14, 2012

Remove an item from the list

I am creating a list where I am adding items from the list through a json data.
The problem i am facing is that I have a delete button, and on click of the button,
the selected item from the list has to be deleted from the store.



This is what i have tried



{
text: '',
id: 'deletenotesBtn',
iconCls:'trash',
iconMask: true,
ui:'action',
handler: function(){
var itemSelected = Ext.getCmp('noteslist').getSelection().remove();
// this.remove(this, true);
alert('item deleted');
}


Any suggestions on how i can achieve it?





No comments:

Post a Comment