C#遍历控件

//遍历TextBox控件

foreach (Control item in this.Controls)
            {
                if (item is TextBox)
                {
                    item.Text = "";
                }
            }

posted @ 2019-02-20 22:46  崇尚技术  阅读(1627)  评论(0编辑  收藏  举报