Time stamp when data entered into a cell

M

Mike

Is it possible to automatically create a time stamp for
when data is entered into a different cell. In Column A I
am collecting data via a barcode reader. For each data
record in Column A I would like to automatically record a
time stamp into Column B of when the data in Column A was
entered. Is this possible?

Mike
 
P

Paul B

Mike, try this in the worksheet code

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
'will put date in column B when something is put in A
If Target.Count > 1 Then Exit Sub
If Target.Column = 1 Then
Target.Offset(0, 1).Value = Now()
End If
End Sub

--
Paul B
Always backup your data before trying something new
Using Excel 97 & 2000
Please post any response to the newsgroups so others can benefit from it
** remove news from my email address to reply by email **
 

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

Top