asp.net中ScriptManager是做什么用的

https://zhidao.baidu.com/question/477322362.html

命名空间:
System.Web.UI
程序集:
System.Web.Extensions.dll

功能跟Page上的ClientScript差不多,不过主要是用来支持ASP.NET Ajax Framework的,你可以用ScriptManager来加载一些script资源,而不会阻挡页面进程。

ScriptManager.RegisterStartupScript(this, typeof(Page), "alert", "alert('No Empty fields are allowed.');", true);

ScriptManager.RegisterStartupScript(Page, this.Page.GetType(), "click", "alert('1');", true);

posted @ 2022-11-22 13:44  yinghualeihenmei  阅读(17)  评论(0编辑  收藏  举报