遍历控件,并将它们的值值为空

来源:互联网 发布:2017明教成男捏脸数据 编辑:程序博客网 时间:2024/04/29 05:52
foreach (System.Windows.Forms.Control control in this.Controls) { if (control is System.Windows.Forms.TextBox) { System.Windows.Forms.TextBox tb = (System.Windows.Forms.TextBox)control ; tb.Text = String.Empty ; } }
原创粉丝点击