Time stamp - data input to row

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I have an Excel spreadsheet with almost 2000 rows of data presently.
For future data input, need to capture two additional info in two more
columns.

one which capture the date on which data is input into a blank row anywhere

and second column the date on which any data is modified in any row but on
specified columns-say column B, C, D , E and F

lastly for the existing 2000 rows, the date created and date modified column
can take arbitrary date of 07/01/2006.

Help please.

George V
 
Hi George, not exactly what you wanted, but this could get you going towards
your need. This example is for A1:100 and D1 to D100. Also do a search on
this site.

Private Sub Worksheet_Change(ByVal Target As Range)

On Error GoTo ws_exit:
Application.EnableEvents = False
If Not Intersect(Target, Me.Range("A1:A100")) Is Nothing Then
With Target
.Offset(0, 6).Value = Format(Now, "dd mmm yy hh:mm:ss")
.Offset(0, 7).Value = Environ("UserName")
End With
End If
Application.EnableEvents = False
If Not Intersect(Target, Me.Range("D1:D100")) Is Nothing Then
With Target
.Offset(0, 3).Value = Format(Now, "dd mmm yy hh:mm:ss")
.Offset(0, 4).Value = Environ("UserName")
End With
End If



ws_exit:
Application.EnableEvents = True
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top