Select All items of a ListView (custom row with checkbox in it)
问题 What I have: I have a ListView with custom rows, having a CheckBox & two TextViews in each row. I have a button for "Select All". What i want: I want that when I click the button, all the CheckBox in ListView get checked/unchecked. What is the problem: In OnClick of the "Select All" button. i am doing this: public void OnClickSelectAllButton(View view) { ListView l = getListView(); int count = l.getCount(); for(int i=0; i<count; ++i) { ViewGroup row = (ViewGroup)l.getChildAt(i); CheckBox