View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Wes[_3_] Wes[_3_] is offline
external usenet poster
 
Posts: 5
Default Adding Checkboxes

Thanks for your help!


-----Original Message-----
Wes,

I like to avoid the Check boxes. You can use one of

these to use the mouse
click to put an X in column 2. (change to WingDings font

and the
appropriate character, you can get a check mark)

Private Sub Worksheet_BeforeDoubleClick(ByVal Target As

Excel.Range, Cancel
As Boolean)
If Target.Column = 2 Then
If IsEmpty(Target) Then
Target = "X"
Else
Target.ClearContents
End If
End If
Cancel = True ' deselects the cell
End Sub

Private Sub Worksheet_BeforeRightClick(ByVal Target As

Excel.Range, Cancel
As Boolean)
If Target.Column = 2 Then
If IsEmpty(Target) Then
Target = "X"
Else
Target.ClearContents
End If
Cancel = True ' turns off the menu
End If
End Sub


steve

"Shunt" wrote in message
...
I think you will find that the easiest way is to first
record a macro that creates one checkbox in the place

you
want.

Then access your macro behind the add button and try a
merge the two macros.

I guess you will have to have some incrementing variable
so you know how many names you have entered and

therefore
where to place the checkbox.



.