private void ClearAllText(System
{
int ctl_count=contrl
for (int i=
{
foreach(Control ctl in contrl
{
if (ctl
{
ClearAllText(ctl
}
else
{
if (ctl is TextBox)
(ctl as TextBox)
}
}
}
}
在頁面中添加一個按鈕
復制代碼 代碼如下:
ClearAllText(this
以上代碼僅供學習
From:http://tw.wingwit.com/Article/program/net/201311/14130.html