Need help with automatic date entry

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

Guest

In a sheet used as a data base, how do I have the current date updated or
changed when the data changes in a record or row. I would like this to show
when that record has been modified with out manually changing that cell.
 
Hi

Rightclick the sheet tab, choose "view code", paste this macro in:

Private Sub Worksheet_Change(ByVal Target As Range)
If Target(1).Column < 5 Then _
Cells(Target(1).Row, 5).Value = Now

End Sub

Replace 5 with whichever column number your dates are stored in.

HTH. Best wishes Harald
 
You can do this with a worksheet_change event macro which is told to use
date in the cell if cells in the row have changed.
 

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