Hi,
You can use as below code(javascript+c#)
public void msgbox(string message)
{
string msg = @"alert('" + message + "');";
ScriptManager.RegisterStartupScript(this, this.GetType(), "s1", msg, true);
}
Source :
Message Box in Asp.Net C#[
^]
If you find it helps you please mark as ans & vote also
Hemant Singh