To show a message box from the ASP.NET page code behind, we could try to ways:
-
When no Ajax is used:
-
When Ajax is used:
-
ScriptManager.RegisterStartupScript(this, this.GetType(), "Key", String.Format("alert('The {0} Class has been approved.');", Detail.Title), true);