如何删除列表视图的所有项目 [英] How to remove listview all items

查看:118
本文介绍了如何删除列表视图的所有项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的应用程序,如果你点击该按钮,然后我想删除所有列表视图项目。 在这里,我使用的基本适配器添加项目到列表视图。

In my app, if you click on the button then i want to remove the all the listview items . Here i am using the base adapter for adding the items to the list view.

如何动态删除列表视图中的项目。

How to remove the list view items dynamically.

推荐答案

呼叫 setListAdapter()了。这一次与空的ArrayList

Call setListAdapter() again. This time with an empty ArrayList.

这篇关于如何删除列表视图的所有项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆