Redirect to self while maintaining view state

G

Guest

I am trying to redirect to the same page after a post-back is fired to ensure
that the post-back never makes it into history (avoids the post-back/refresh
problem). While doing this, I wish to maintain the view state of the page
(page contains dynamic controls as well). Has anybody done this before? I
assume that I need to store the viewstate info in session (as the 64-bit
encoded string or as the statebag? using sql server session statehandler, not
sure if statebag would be acceptable in that case), and then read from that
session-stored view state when the page loads? Any help would be greatly
appreciated.

Thanks
 
T

Teemu Keiski

If you make yourself sure that your dynamical controls participate the
viewstatate loading and saving normally, that is they work on nomal page,
they would work with this approach as well.

Can you describe your scenario more accurately?
-
Teemu Keiski
ASP.NET MVP, AspInsider
Finland, EU
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,015
Latest member
AmbrosePal

Latest Threads

Top