C#后台无刷新页面弹出alert方法

无刷新弹出警告:       

ScriptManager.RegisterStartupScript(this.Page, this.GetType(),"onekey", "alert('弹出')", true);

 

而以下方法,会刷新弹出,比较难看

Response.Write("<script>alert('弹出')</script>");

ClientScript.RegisterStartupScript(this.Page, this.GetType(),"onekey", "alert('弹出')", true);

posted @ 2012-09-04 16:38  随风任飘遥  阅读(9085)  评论(0编辑  收藏  举报
1、不要犯经验主义的错误,有些经验可能是错误的。 2、发现bug要及时处理,不可为了赶工而忽略。随机性出现的bug更要注意,因为这类bug更难发现,也就更能解决。