An easy way to do this is put tags on them in their TAG property, e.g. Group1, Group2, etc.
Then you can cycle enable/disable them in one shot.
Dim ctlMyControl as Control
For Each ctlMyControl in Me
If ctlMyControl.Tag = "Group1" Then
ctlMyControl.Enable = True
End IF
Next ctlMyControl
Greg Serrano
Michigan Dept. of Environmental Quality, Air Quality Division
|