How to use Server.Transfer or Response.Redirect from ajax UpdatePanel?
A:
Never mind, i just found out myself
use javascript inside ur Updatepanel like the code below.
c# code:
String TransferPage = "window.open('Gallery-Page.aspx','_self');";
ScriptManager.RegisterStartupScript(Page, Page.GetType(), "temp", TransferPage, false);
Even u can give hyperlink instead of "Gallery-Page.aspx"
Thanks,
Asem Ibohal
Asem Ibohal
2010-02-05 11:51:54
@Eibx's solution using window.location is better, IMO.
tvanfosson
2010-02-05 11:56:41
+1
A:
Without being harsh, it really doesn't make sense to be able to. I think some reading about AJAX would make it clear.
But you could write following to the browser.
<script type="text/javascript">window.location = "URL"</script>
Eibx
2010-02-05 11:52:30
A:
UpdatePanel supports Response.Redirect. It works OK for me. What error do you get?
thorn
2010-02-05 12:52:27
A:
Here is blog post that will help you to resolve the issue.
http://patelshailesh.com/index.php/response-redirect-throws-an-error-when-called-inside-update-panel
shailesh
2010-09-20 20:16:26