If these are your requirements, then yes. At any one time, you should only
retrieve the records you need though. So if you are display 10 at a time,
grab 1-10 the first time, when they hit Next, grab the next 10.
The other way you could do it, is to assign each page a new GUID on the
first page_load and store the GUID in viewstate. Then, if your session
variable name is "SearchResults", name it : GUID + "SearchResults". That
way there will be unique session variables for each page, since each one
will have a unique guid that it has created at start up. This works if you
don't mind having multiple sets of data in session at the same time.
"Vik" <viktorum@==hotmail.com==> wrote in message
news:ux**************@TK2MSFTNGP11.phx.gbl...
A Web page contains a search function, which fills out a dataset and
stores it in a Session state. A user can navigate through the stored records. If
the user opens a new browser window from the existing one and enters
another search criteria, then the new dataset overrides the dataset from the
previous window in the session state and both windows display the same
results though the search criteria look different.
When the dataset is stored in a view state loading the page takes forever.
How can I solve this problem? Should I retrieve data from a database every
time the page is loaded?
Thanks.