遇到清空大量TextBox内容的操作,操作如下:

protected void Clear(Control ctrl)
  {
   foreach (Control c in ctrl.Controls)
   {
    if (c is TextBox)
    {
     ( ( TextBox ) ( c ) ).Text = "";
    }
    c.Text = "";
    Clear(c);
   }
  }
然后调用就可以

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-14
  • 2022-12-23
  • 2021-07-21
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-05-21
  • 2021-11-25
  • 2022-12-23
  • 2021-12-30
  • 2022-12-23
相关资源
相似解决方案