underpressure
Board Regular
- Joined
- Nov 24, 2012
- Messages
- 141
I plan to add 50 CheckBoxes to a ws in my project.
Other than creating 50 Subs to handle these events, can I get suggestions on how to:
Other than creating 50 Subs to handle these events, can I get suggestions on how to:
Code:
Sub CheckBox3_Click()
Application.ScreenUpdating = False
If CheckBox3.Value = True Then
Range([COLOR=#ff0000]"B3:V3"[/COLOR]).Select
With Selection.Font
.ThemeColor = xlThemeColorDark1
.TintAndShade = -0.5
End With
Else
Range([COLOR=#ff0000]"B3:V3"[/COLOR]).Select
With Selection.Font
.Color = vbRed
.Bold = True
End With
End If
End Sub
_______________________________________________________________
Sub CheckBox4_Click()
Application.ScreenUpdating = False
If CheckBox4.Value = True Then
Range([COLOR=#ff0000]"B4:V4"[/COLOR]).Select
With Selection.Font
.ThemeColor = xlThemeColorDark1
.TintAndShade = -0.5
End With
Else
Range([COLOR=#ff0000]"B4:V4"[/COLOR]).Select
With Selection.Font
.Color = vbRed
.Bold = True
End With
End If
End Sub