How can I create remove method in list Adapter to remove row of list view
and how to use this method in my Activity
?
public void remove(List<contac> contac) {
list.remove(contac);
}
In my Activity
:
adapter.remove(list.get(i));
but it didn't worked, if I use this
list.remove(i);
worked but after refreshing not changed my list view. then use update method:
public void updateList(List<contac> list) {
this.list = list;
notifyDataSetChanged();
}
Again it didn't work. Any ideas ?