Remember ViewState after Redirect

J

Joe Kovac

Hi!

I have an edit page and a view page. When I edit I sometimes want to see
the results graphically in the view page. Therefore I use:

Response.Redirect("ViewPage.aspx");

Then I go back, using:

Response.Redirect("EditPage.aspx");

Coming back I don't have the view state of my edit page anymore (for
example clicked check boxes get reset). How can I avoid that easily? Or
must I use session variables for this use case?

Thanks

Joe
 
M

Mark Rae

Coming back I don't have the view state of my edit page anymore (for
example clicked check boxes get reset).

Indeed not - that's not what ViewState is...
How can I avoid that easily? Or must I use session variables for this use
case?

Session variables would be one way.

Alternatively, you could open your View page in a new window - you could
even use a modalDialog if this is an enclosed system and all your client
machines use IE...
 

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

Top