The most common method is
Response. Write ("<SCRIPT> alert ('White background! '); </SCRIPT>");
In this method, the background is white when a message box is displayed.
Page. clientscript. registerstartupscript (page. GetType (),"Message","<Script language = 'javascript 'defer> alert ('the background is not white! '); </SCRIPT>");
//. Net After Code Enter the JS prompt statement (the background will not be white) page. clientscript. registerstartupscript (page. getType (), "message", "<script language = 'javascript 'defer> alert (' added to the storage shelf successfully! '); </SCRIPT> "); // The page is redirected. clientscript. registerstartupscript (page. getType (), "message", "<script language = 'javascript 'defer> alert ('Congratulations, modification successful! '); Window. Location = 'default. aspx' </SCRIPT> "); similar to Ajax, the page is not refreshed !!!