Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
checkbox macro
I have created a macro:
Private Sub CheckBox131_Click() Range("C26:G26").Select Selection.Font.ColorIndex = 5 whenever I click the checkbox the text changes the color. However if I uncheck the checkbox I would like the colour to go back to automatic black. And then if I check it again I would like text to change color. thanks Dajana |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
checkbox macro
Hi Dajana,
Try this Sub CheckBox1_Click() ActiveSheet.Shapes("check box 131").Select If Selection.Value = xlOn Then Range("C26:G26").Select Selection.Font.ColorIndex = 5 Else Range("C26:G26").Select Selection.Font.ColorIndex = 1 End If - Search "Dajana" wrote: I have created a macro: Private Sub CheckBox131_Click() Range("C26:G26").Select Selection.Font.ColorIndex = 5 whenever I click the checkbox the text changes the color. However if I uncheck the checkbox I would like the colour to go back to automatic black. And then if I check it again I would like text to change color. thanks Dajana |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Closing File Error | Excel Discussion (Misc queries) | |||
Macro for checkbox (2) | Excel Discussion (Misc queries) | |||
Macro for checkbox (2) | Excel Discussion (Misc queries) | |||
Macro for checkbox | Excel Discussion (Misc queries) | |||
Date macro | Excel Discussion (Misc queries) |