Adding checkboxes programmatically to a worksheet

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Sorry, my last message just went out of my hands.

I add some checkboxes to a worksheet where the user can check/uncheck for
one of two options. I set the default value to False. Now I cannot figure out
how to make the checkbox work since I cannot write the code Sub
Checkbox1_Click. How do I do that and how do I find and store the value (True
or False) in either a cell or in a variable.
 
Select the checkbox and right-click and choose Format Control
Select the Control tab and add a cell address to the Cell link dialog.
The value of the linked cell will change to TRUE or FALSE depending on
whether the check box is ticked or not. Use in functions like =IF(C1, then
else) where C1 is the cell containing the result.
 
Ben gave you the procedure for a check box from the forms toolbar. There is
also a control toolbox toolbar that has checkboxes. Which are you using as
the procedures are somewhat different for each.
 
Back
Top