Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
If [A2].Value = 0 Then
If Intersect(Target, Cells) Is Nothing Then Exit Sub
[A2].Value = 1
Cancel = True
Else
If Intersect(Target, Cells) Is Nothing Then Exit Sub
[A2].Value = 0
Cancel = True
End If
End Sub