ASP.NET Déconsider le script client
protected void Page_Load(object sender, EventArgs e)
{
if (!this.IsPostBack)
{
if (Session["info"] == null)
{
string message = "Information to display";
ClientScript.RegisterStartupScript(this.GetType(), "Popup", "alert('" + message + "');", true);
Session["info"] = true;
}
else
{
//Remove the script
ClientScript.RegisterStartupScript(this.GetType(), "Popup", "", false);
}
}
}
Darker