使用asp.net自带的ajax控件,想要调用后台的脚本代码,最先开始用
ClientScript.RegisterStartupScript(this.GetType(), "clear", "<script>alert('更改失败。');</script>");
一直执行不成功,后来改用
ScriptManager.RegisterStartupScript(this.UpdatePanel1, this.GetType(), "msg2", "alert('更改失败。'); ", true);
可正常执行。