Asma Siddiqua

Asma Siddiqua

  • NA
  • 23
  • 5.7k

redirect back from folder by window.location with alert mess

Jun 20 2015 4:34 AM

How to redirect back from folder by window.location with alert message in asp.net c#

I tried like below many methodes some are responding resource not found and some are reloading same page unlimited time.

ScriptManager.RegisterStartupScript(this, this.GetType(), "redirect", "alert('test 9'); window.location='" + HttpRuntime.AppDomainAppPath + "/LoginPage.aspx';", true);       
ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "ScriptKey", "alert('Your session timed out.');window.location='../LoginPage.aspx'; ", true);    
ScriptManager.RegisterStartupScript(this, this.GetType(), "alert", "alert('Your session timed out');window.location.href ='../LoginPage.aspx';", true);
 

Answers (2)