Search to show a new intent? [closed]
maybe some one can help me with this... I have a custom search button (i do have the google search as well but I need this)..
here is the scenario:
on main page I have list of records
I click on the search button which shows list of tags that I can click on for the system to search
-I return to the main page with a string telling me which records to view
-the main page shows those records
this is all fine, but the problem is if I click back the app quits, which is understandable and what is suppose to happen. what I want is the same as the android search function where it opens the result in a new page and when I click back it takes me to my full list
Cursor notesCursor3 = mDbHelper.fetchSearchTagNotes(matchNotes);
startManagingCursor(notesCursor3);
String[] from = new String[]{NotesDbAdapter.KEY_TITLE,NotesDbAdapter.KEY_CREATEDON};
int[] to = new int[]{R.id.text1,R.id.date};
SimpleCursorAdapter notes = new SimpleCursorAdapter(this, R.layout.notes_row, notesCursor3, 开发者_如何学运维from, to);
setListAdapter(notes);
this is my simple code after getting the search result, which is simply changing the adapter to the list (I do the same for the default android search which works like I said).
Never mind the question. I had to succumb to my inability to find an answer and create a custom intent to do this
精彩评论