例如,当我向数据库添加一行时,我运行ff。代码,如何在数据库更改时重新引导光标适配器?
Cursor crs = adapterToRefresh.getCursor();
crs.close();
crs = this.dbImmunization.queryAll();
this.startManagingCursor(crs);
crs.moveToFirst();
adapterToRefresh.changeCursor(crs);
adapterToRefresh.notifyDataSetChanged();
其中crs是游标在游标适配器内的检索。
到目前为止,这个实现给了我一个CursorIndexOutOfBoundsException的错误。
帮助任何人!
请发布堆栈跟踪。 – trojanfoe 2011-05-04 09:46:09