Good Evening Guys, Today its my Birthaday.

I have a If statement that i use to return an integer that will mean Success or Failure , now am testing for that integer in my ASP.NET 2.0 Page lke this

if (Res == 1)
        {

          
 Response.Write("<script> alert('You have Successfully Registred');</script>");
           

 Response.Redirect("login.aspx", false);
        }
        else
        {

          
          
Response.Write("<script> alert('Invalid Data has been Entered');</script>");
       

        }

Now if the value is 1, then it should Display the Message and after the Message has been Clicked it should move to the login Page. Now my Problem is that it moves to the Login Page without a Alert Message being Displayed And the send Alert for invalid Entry, will not show anythingm, there is a Warning sign on my Page at the Bootom left of my Page. What is wrong with my Javascript

Thanks

the methodu u used is obselete in case of asp.net 2.0 ,u should javascript like this

ClientScript.RegisterStartupScript(this.GetType(), "msg", "<script> alert('Machine Details Added Successfully!'); </script>");
This question has already been answered. Start a new discussion instead.