I currently have a custom listview where each item on the list contains two rows of text. What I would like to do is each time a user clicks on the button, it creates a new
After calling fillData(), just make a call on adapter.notifyDataSetChanged()
.
NotifyDataSetChanged() - Notifies the attached View that the underlying data has been changed and it should refresh itself.
It's as simple as adding a new element to your ArrayList
(like you do in fillData
), then calling adapter.notifyDataSetChanged()
.