Update cell with change date

  • Thread starter Thread starter Andrew
  • Start date Start date
A

Andrew

I have a sheet where I store prices. Is there a way to
return the date I changed a given cell in another cell?
e.g. If I update the info in cell A2, how do I get A3 to
return the date I changed the value of A2?
 
Sorry I'm not clear enough.
A2:G2 contain my data.
A3:G3 contain the dates the data in the cell above was
changed. Can the cells in Row 3 be automated?
 
Only with a macro in the worksheet's code module:

Private Sub Worksheet_Change(ByVal Target As Range)
If Not Intersect(Target, Range("A2:G2")) Is Nothing Then _
Target.Offset(1) = Date
End Sub
 
Insert this in your say sheet1 (where you are performing the work);

Private Sub Worksheet_Change(ByVal Target As Range)
If (Target.Row = 2 And Target.Column >= 1 And Target.Column <= 7) Then
Target.Offset(1, 0).Value = Format(Now, "mm-dd-yyyy hh:mm:ss")
End If
End Sub

HTH
 
Back
Top