Вы можете набрать
static class ControlExtension
{
public static IEnumerable<Control> GetAllControls(this Control parent)
{
foreach (Control control in parent.Controls)
{
yield return control;
foreach (Control descendant in control.GetAllControls())
{
yield return descendant;
}
}
}
}
и позвонить
this.GetAllControls().OfType<TextBox>().ToList().ForEach(t => t.ID = Guid.NewGuid().ToString());