以文本方式查看主题

-  Foxtable(狐表)  (http://www.foxtable.com/bbs/index.asp)
--  专家坐堂  (http://www.foxtable.com/bbs/list.asp?boardid=2)
----  关于窗口  (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=151293)

--  作者:ygg8310
--  发布时间:2020/6/19 17:04:00
--  关于窗口
For Each c As Winform.Control In e.Form.Controls
    c.BackColor = Color.Green
Next
我想在这个里面排除某个或多个控件,这个代码怎么写?

--  作者:有点蓝
--  发布时间:2020/6/19 17:15:00
--  
排除什么控件?
--  作者:ygg8310
--  发布时间:2020/6/19 17:39:00
--  
比如button1 button2
--  作者:有点蓝
--  发布时间:2020/6/19 17:44:00
--  
For Each c As Winform.Control In e.Form.Controls
If Typeof c Is WinForm.button andalso  c.name = "button1" Then continue for
    c.BackColor = Color.Green
Next