trouble using checkbox26_DblClick

J

JL

I am trying to doubleclick checkbox26 and make value of cell D10 = "N/A" as
well as clear tick in checkbox26. But then if the user later wants to go
back and single click checkbox26 I need to clear the "N/A" and have the
checkbox operate as normal. Here's what I have:

Private Sub CheckBox26_Click()
Range("D10").Value = "N/A"
End Sub

Private Sub CheckBox26_DblClick(ByVal Cancel As ReturnBoolean)
Range("D10").Value = "N/A"
CheckBox26.Value = False
End Sub

It works one time but then will not clear D10.
 
B

Bob Umlas, Excel MVP

You can't have both a click and dbl click event for this - the first click of
your double-click will just fire the click event, and you'll never be able to
fire the dbl-click event. You can confirm this by having a msgbox for each
procedure and you'll see you can only see the msgbox for the click event.
Bob Umlas
Excel MVP
 

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