//On a Form
foreach(Control ctl in this.Controls)
{
if (ctl is TextBox)
(ctl as TextBox).Text = "";
} //On Group Control
foreach (Control ctrls in gcGeneralInfo.Controls)
{
if (ctrls is TextBox)
ctrls.Text = string.Empty;
}
No comments:
Post a Comment