Hi,
I'm using this codes for the date time stamp and updated by username for my excel. But I got a problem.
(1) I got a row which is the header but I do not want the formula to run on this header if I made changes to it. How do I tweak my current codes?
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count > 1 Or IsEmpty(Target) Then Exit Sub
If Not Intersect(Target, Range("A:X")) Is Nothing Then
Application.EnableEvents = False
Intersect(Target.EntireRow, Columns("Y")) = Now()
Intersect(Target.EntireRow, Columns("X")) = Environ("USERNAME")
Application.EnableEvents = True
End If
End Sub
(2) If I insert a row, the system will prompt debug. How do I overcome this?
Your expertise in this is greatly appreciated.
Thank you.
Bookmarks