Private Sub Worksheet_Change(ByVal Target As Excel.Range)
With Target
If .Count > 1 Then Exit Sub
If Not Intersect(Range("A8:A9999"), .Cells) Is Nothing Then
Application.EnableEvents = False
If IsEmpty(.Value) Then
.Offset(0, 1).ClearContents
Else
With .Offset(0, 1)
.NumberFormat = "dd mmm yyyy h:mm:ss AM/PM"
.Value = Now
End With
End If
Application.EnableEvents = True
End If
End With
remove the next 3 lines
'End Sub
'__________________________________________________ ____
'Private Sub Worksheet_Change(ByVal Target As Excel.Range)
With Target
If .Count > 1 Then Exit Sub
If Not Intersect(Range("J8:J9999"), .Cells) Is Nothing Then
Application.EnableEvents = False
If IsEmpty(.Value) Then
.Offset(0, 1).ClearContents
Else
With .Offset(0, 1)
.NumberFormat = "dd mmm yyyy h:mm:ss AM/PM"
.Value = Now
End With
End If
Application.EnableEvents = True
End If
End With
End Sub
Bookmarks