CheckBox assistance?

J

Jacob Lane, MCP

Hello-

I am trying to create a checkbox in my spreadsheet that will change the font
color of a range of cells when checked. I have two questions about doing this:

1. How do I assign code to a specific checkbox? It doesn't seem very
intuitive.

2. Are there examples of how to do such things online?

Thanks.

Jake
 
G

Gary Keramidas

this will make the font bold in a1:a10 if the box is checked and normal font
if the box is unchecked


Private Sub CheckBox1_Click()
If CheckBox1.Value = True Then
Range("A2:a10").Font.Bold = True
Else
Range("A2:a10").Font.Bold = False
End If
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top