遍历aspx页面中所有的指定控件 最新更新| 软件分类| 专题汇总| 手机版

您所在的位置:首页 > 遍历aspx页面中所有的指定控件 > 信息评论 >

遍历aspx页面中所有的指定控件

  //1.遍历页面中所有的TextBox,并将值设置成String.Empty  for (int j = 0; j < this.Controls.Count; j++)  {  foreach (object o in Page.Controls[j].Controls)  {  if (o is TextBox)  {  TextBox txt = (System.Web.UI.WebControls.TextB

网友评论

发表评论

(您的评论需要经过审核才能显示)