1
  String[] mListContent={"Sunday", "Monday", "Tuesday", "Wedneday", "Thursday", "Friday", "Saturday"};
  setListAdapter( new AlarmDaysAdapter(this, android.R.layout.simple_list_item_checked, mListContent));
  ListView listView = getListView();
  listView.setChoiceMode(ListView.CHOICE_MODE_MULTIPLE);      
  for(ii=0; ii<values.size(); ii++)
  {
      listView.setItemChecked(values.get(ii),true);
      Log.i(" values: " + values.get(ii)," ");
  }

我想在显示Listview. Log.i 打印出完美的值,values.get(ii)即默认情况下我想要检查的位置。我怎样才能实现它?

4

0 回答 0