DataScroller, table page navigation problem
In my case I have created page with table and datascroller. I navigate from this page to another page and then back. But here is a problem. If I begin, for example, from 3rd page of data scroller and return back, the datascroller alwas positions on first page! I wold like to return on the same page (as indicated on data scroller). What is the solution?
Regards Simy
[380 byte] By [
Simya] at [2007-10-2 6:40:01]

This is only idea. I'm not shure this idea will work.
You should save state on page with dataScroller and then when you return - restore state.
I know the follow idea will work. You can create new component and inherit it from dataScroller. Then create you owner bean which store current position of scroll and hold this bean in session.
-aba at 2007-7-16 13:48:15 >

I am experimenting with method setFirst(int) on HtmlDataTable component. Somewhere I have noticed that page on HtmlDataScroller is defined by setFirst(int). So in the moment when I navigate to page where HtmlDataTable is, I set method parameter to appropriate value. This is done in afterPhase method of phase listener, but it obviosly does not work, because only RENDER_RESPONSE is triggered when I return to page. Questions:
1.) Is using setFirst(int) right way?
2.) In which phase of lifecycle should be used?
3.) How to trigger other lifecycle phases, not only RENDER_RESPONSE?
Regards Simy
Simya at 2007-7-16 13:48:15 >
