Thursday, 5 December 2013

SOLVED: Session Lost problem after Response.Redirect when redirect from Iframe

Copy & Paste this to head tag:

<script type="text/javascript" language="javascript">
      
        //for Redirect Iframe
        function Redirect() 
        {
            top.location = "Checkout.aspx";
            return false;
        }

</script>


Copy & Paste this code on .cs file:

ScriptManager.RegisterStartupScript(Page, typeof(System.Web.UI.Page),
                                                    "blur", @"<script type='text/javascript'>Redirect();</script>", false);

Note: bool value set true if you don't use UpdatePanel......

No comments:

Post a Comment