Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

asp.net unregister client script

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);
        }
    }
}
Comment

PREVIOUS NEXT
Code Example
Csharp :: Fibonacci Ienumerable 
Csharp :: C# read GroupComponent Or PartComponent using regex 
Csharp :: distinct and not null c# 
Csharp :: json string to JObject object c# camelCasing key .net 
Csharp :: advance C# tricks and hits 
Csharp :: get access to all controls with a specific tag in C# 
Csharp :: how to pass id to modal in asp.net mvc 
Csharp :: viewresolver cyrillic 
Csharp :: c# condition and 
Csharp :: CRUD configuration MVC with Firebase 
Csharp :: C# if...else if Statement 
Csharp :: how to write an if statement with two checkboxes in c# 
Csharp :: tab key navigation C# winforms 
Csharp :: panning script c# on phone 
Csharp :: c# linq get one object 
Csharp :: nunit return parameter 
Csharp :: vb.net single quote in string 
Csharp :: c# label continue in new line 
Csharp :: regex ip rage detect c# 
Csharp :: dotnet.com 
Csharp :: unity bool to int 
Csharp :: qrcode c# 
Csharp :: how to delete file in c# 
Csharp :: c# optional parameters using 
Csharp :: unity error cs1656 
Csharp :: use different database with entitymanagerfactory 
Html :: fevicon 
Html :: bootstrap text bold 
Html :: connecting metamask to binance smart chain 
Html :: upload only image input tag 
ADD CONTENT
Topic
Content
Source link
Name
2+7 =