Sunday, September 21, 2008

Redirecting browser to a different page during an asynchronous callback of the WebAsyncRefreshPanel

When not processing an asynchronous callback through the WebAsyncRefreshPanel, the following code will tell the browser to navigate to a different page:

In C#:

Response.Redirect("NewPage.aspx", true);

LiteralControl c = new LiteralControl("");
this.WebAsyncRefreshPanel1.Controls.Add(c);

No comments: