tonywatsonhelp
Well-known Member
- Joined
- Feb 24, 2014
- Messages
- 3,210
- Office Version
- 365
- 2019
- 2016
- Platform
- Windows
Hi Everyone,
I have the macro below which I use to treat my own tick boxes in cells "a" = tick
It works great except you have to click away before it will change again.
I was woundering if there was a bettter way i could do this?
Basickly I want a macro that gives me an "a" in the cell i click on if its empty and "" if it has an "a"
Heres my code:
I have the macro below which I use to treat my own tick boxes in cells "a" = tick
It works great except you have to click away before it will change again.
I was woundering if there was a bettter way i could do this?
Basickly I want a macro that gives me an "a" in the cell i click on if its empty and "" if it has an "a"
Heres my code:
Code:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Selected Target
End Sub
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
Selected Target
End Sub
Private Sub Selected(ByVal Target As Range)
If Not Intersect(Target, Range("AL52:AL300")) Is Nothing _
And Target.Count = 1 Then
If Target.Value = "" Then
Target = "a"
Else
Target = ""
End If
End If
End Sub