im using ajax pop up . to show the invalid user aceess and then redirecting to home.aspx page, for unauthorised users its redirecting to home.aspx page but pop is not showing that illegal access.
i want to show pop up of illegal access and go to home.aspx or else show the pop up and should not render anything in that page
Pop is not showing
protected void Page_Load(object sender, EventArgs e)
{
if (Session["LoginUser"].ToString() == "admin" )
{
if (!IsPostBack)
{
if (Session["LoginId"] == null)
{
Response.Redirect("~/Login.aspx");
}
fillProj();
fillYear();
FillUser();
}
}
else
{
ScriptManager.RegisterClientScriptBlock(Page, typeof(Page), "clentscript", "alert('Illegal Accesss..');", true);
Response.Redirect("Home.aspx");
}