1

Android ListView choices are preserved

view story
linux-howto

http://stackoverflow.com – I have an activity as singleTop Here is the part of oncreate() ListView mainListView = (ListView) findViewById(R.id.order_item_list); mainListView.clearChoices(); mainListView.requestLayout(); listAdapter = new OrderItemAdapter(this, R.layout.list_item_order_item, OrderActivity.Order.OrderItems); mainListView.setAdapter(listAdapter); SparseBooleanArray checkedItems= mainListView.getCheckedItemPositions(); Log.println(2, "s", Integer.toString(checkedItems.size() )); } Using debuger checkedItems is 0 then. But when i get it from action click it t (HowTos)