example of rehydrating a search view


  • Hi

    I've seen a number of articles saying that when you implement search you need to save the search state in case the application gets suspended and then "rehydrate" the search view when the application gets restored from the suspended state. I take this to mean that the search term gets saved as an object in the sessionstate and then when you resume the app you conduct that same search with the stored string.

    Is this correct? and if so does anyone have a practical example of this that I could look at?



    Tuesday, November 6, 2012 3:24 PM


  • Well if I understand it correctly, you are trying to figure out how state changes work with search.....
    let me put this scenario... you have a search screen with 3 dropdown filters..... the values which you set in these dropdowns are part of your search state and in case if you do not save it while the app goes to suspension and then gets restored, you will eventually lose them.

    so you need to explicitly store those values .

    As far as the search term/text is concerned, winRT takes care of it.......

    to evaluate this scenario, you may try this approach, run the app and suspend it (using visual studio), and then go to start screen, invoke search charm-> select the same app and then hit search again.....hope it helps....

    Arindam Basu

    Thursday, November 8, 2012 7:15 PM