My problem: My ListView resets its scroll position to the top whenever I update its contents through its (customized) SimpleCursorAdapter. I would like the ListView to main
Did the same in post execute of Async Task used following code worked for me
Cursor cursor = mDataHelper.getWritableDatabase().query(
DataContract.Incares.TABLE_NAME, // Table to Query
null, // all columns
null, // Columns for the "where" clause
null, // Values for the "where" clause
null, // columns to group by
null, // columns to filter by row groups
DataContract.Incares.UUID +" DESC" // sort order
);
CursorAdapter.swapCursor(cursor);
CursorAdapter.notifyDataSetChanged();
with CursorAdapter being a global variable