Here if you want to show alert box from the server side code.Incase the button has inside the update panel you must follow this below code

ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "Key", "alert('alert box.');", true);

 In case if we want to redirect to another page after a showing alert message...Try this below code

ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "Key", "alert('alert box.');window.open('defult.aspx','_parent');", true);

VB Code:

ScriptManager.RegisterClientScriptBlock(Me, GetType(Type), "key", "alert('alert box.');window.open('defult.aspx','_parent');", True)


I hope you read something useful to u

0 comments:

Post a Comment