谁能帮我下,如何循环批量给40个textbox控件的backcolor属性赋值,多谢了!
谁能帮我下,如何循环批量给40个textbox控件的backcolor属性赋值,多谢了!
程序代码:
Control.ControlCollection cc = this.Controls; foreach (Control ct in cc) { if (ct is TextBox) { ct.BackColor = Color.Red; } }