如果页面中不用Ajax,cs中运行某段js代码方式可以是:Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "<script>window.open('default2.aspx')</script>");如果页面中使用了Ajax ,则上述代码即使执行也无效果。对这种情况我们通常采用:ScriptManager.RegisterStartupScript(this.Button1, this.GetType(), "alertScrip Read More
posted @ 2012-01-13 09:07 FredTang Views(210) Comments(0) Diggs(0)