如何在新数组

时间:2017-04-05 19:45:32

标签: android listview android-adapter

这是我在xml文件中的listView

 <ListView
    android:id="@+id/list"
    android:layout_width="match_parent"
    android:layout_height="match_parent" />

这是在ListView

中输入数据的地方
 ListView petListView = (ListView) findViewById(R.id.list);
    //attach empty view
    View emptyView = findViewById(R.id.empty_view);
    petListView.setEmptyView(emptyView);
    //no pet data yet so cursor is set to null
    mCursorAdapter = new PetCursorAdapter(this, null);
    petListView.setAdapter(mCursorAdapter);

在我的listView的子项目中有电话号码,我想将listView中的所有电话号码复制到一个新阵列。

0 个答案:

没有答案