A few questions.
What causes Range "A1" to change.
Is this a manual change or as the result of a formula?
And then what would cause range "A1" to go back to less then 5 ?
Here is a script which would work if you manually change the value in Range ("A1")
And it will reset Range("A1") back to Zero
This is an auto sheet event script
Your Workbook must be Macro enabled
To install this code:
Right-click on the sheet tab
Select View Code from the pop-up context menu
Paste the code in the VBA edit window
Private Sub Worksheet_Change(ByVal Target As Range)
If Not Intersect(Target, Range("A1")) Is Nothing Then
If Target.Cells.Count > 1 Or IsEmpty(Target) Then Exit Sub
If Range("A1").Value > 5 Then
Range("A1").Value = 0