How to show the alert dialog for the empty list view when there are no listview items. Please find the below image having three text fields. I have to implement the empty list view when there are no records/unmatched records in the list.
The list view is implemented as below:
ListView empListView;
empListView = (ListView)findViewById(R.id.list1 );
I have to show the alert dialog box for the empListView. Please help me with the samplecode/links.
It all depends on how you implement the setAdapter method etc. But here is an example:
The code above havent been tested. But should work with minor adjustments, I might have forgotten something.