To prevent the Change event being needlessly invoked a second time (ie when A1 is altered) toggle Events - you might also want to use Val function to avoid possible coercion errors.
Private Sub Worksheet_Change(ByVal Target As Range)
On Error Resume Next
If Not Intersect(Target,Range("A2")) Is Nothing Then
Application.EnableEvents = False
Range("A1") = Val(Range("A1")) + Val(Range("A2"))
Application.EnableEvents = True
End If
End Sub
(you could also add an IsNumeric test if you wanted to prevent numeric alpha strings being counted - eg 1Apple would add 1 to result in above form)
P.S. Are whizbang and I now entitled to free holidays in the Maldives ?
Bookmarks