I want to add/show some message with a OK button in c# asp.net without using the windows.forms name space.
How to show/display message box in C# asp.net forms?
208719-Dec-2014
Home / DeveloperSection / Forums / How to show/display message box in C# asp.net forms?
Mark M
20-Dec-2014One easy solution is to register some JavaScript code in your page:
string script = "alert(\"Hello!\");";
ScriptManager.RegisterStartupScript(this, GetType(),ServerControlScript", script, true);
Anonymous User
20-Dec-2014Use:
string display = "Pop-up!";
ClientScript.RegisterStartupScript(this.GetType(), "yourMessage", "alert('" + display + "');", true);