I have a listView (android.R.layout.simple_list_item_multiple_choice
) where each row of list have a checkbox.
I need to block all checkbox's when click in one button. But I don't know how i can block ALL checkbox's simultaneously.
if(checkAll.isChecked()==true){
all.clear();
//É adicionado cada id ao array list
for(int i=0 ; i<listViewSocios.getCount() ; i++){
listViewSocios.setItemChecked(i, true);
}
}
All the checkbox's in each row are checked but i want also enabled all this checkbox Can you help me? thanks
I try this way but don't work....
for(int i=0 ; i<listViewSocios.getCount() ; i++){
listViewSocios.setItemChecked(i, true);
CheckBox cb = (CheckBox)listViewSocios.getChildAt(i).findViewById(android.R.id.text1);
cb.setEnabled(false);