Change the password to suit.
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
'Have a Cell Ticked Upon Selection
If Target.Cells.Count > 1 Then Exit Sub
'Isolate Target to a specific range
If Intersect(Target, Range("X_Cells")) Is Nothing Then Exit Sub
ActiveSheet.Unprotect Password:="Secret"
Target.Font.Name = "Arial"
If Target = vbNullString Then
Target = "X"
Else
Target = vbNullString
End If
ActiveSheet.Protect Password:="Secret"
End Sub
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
If Target.Cells.Count > 1 Then Exit Sub
'Isolate Target to a specific range
If Intersect(Target, Range("Tick_Cells")) Is Nothing Then Exit Sub
Cancel = True 'Cancel the double-click edit mode
ActiveSheet.Unprotect Password:="Secret"
Target.Font.Name = "Wingdings"
If Target = vbNullString Then
Target = "ü"
Else
Target = vbNullString
End If
ActiveSheet.Protect Password:="Secret"
End Sub
Bookmarks