SqlDatabase db;
Cursor cur = db.rawQuery("SELECT MAX(_ID) FROM tb_expense;",null);
startManagingCursor(cur);
cur.moveToFirst();
while(!cur.isAfterLast())
{
int id = cur.getInt(0);
txt id1 = id + 1;
txtID.setText(Integer.valueOf(id1).toString());
cur.moveToNext();
}