I am working on restaurant app. In that, i have cart activity. That, I manage with the database. When the user adds an item, i insert it to a database.
I created one class that extends ArrayAdapter
- in this class, i display data of each item in the cart.
- when user finalizes cart items, i post it to WebService.
Problem
- in this cart, itemi have a button "remove this item."
- when I click on it, item is deleted from the database but not reflecting on ArrayList.
adapter.notifyDataSetChanged() not working.
NOTE
when I go back to that activity and come, it will be removed.