listview - Delete a list view Row Titanium -
i want delete row in list view. when user clicks row want open dialog showing message 'sure want delete'. when user clicks ok row should deleted.
listview.addeventlistener('itemclick', function(e){ var section = e.section; var itenindex = e.itemindex; var dialog = ti.ui.createalertdialog({ title : 'do want delete row?', buttonnames : ['yes','no'] }); dialog.addeventlistener('click', function(e){ if(e.index == 0){ section.deleteitemsat(itenindex,1); } }); dialog.show(); });
Comments
Post a Comment