Last Modified date on cell or column

G

Guest

Good Morning,
Can you please advise if there is a way or formula to know when was the last
time a cell, column or row was modified without typing everytime that I
update it.
Example:
A B
Data Last modified date
BER 3/12/2007
BER 3/1/2007
BER 2/18/2007
SPR 2/18/2007
SPR 2/18/2007
PHL 2/18/2007
 
G

Guest

Let's say we enter data in column A and want column B to mark the dte of last
update. So if we enter data into A5, then B5 would automatically record the
date this update occurred. in Worksheet code enter the following macro:

Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Range("A:A"), Target) Is Nothing Then
Exit Sub
End If
Application.EnableEvents = False
Target.Offset(0, 1).Value = Now()
Application.EnableEvents = True
End Sub

REMEMBER: Worksheet code.
 
G

Guest

Thank You. Very Helpful.

Gary''s Student said:
Let's say we enter data in column A and want column B to mark the dte of last
update. So if we enter data into A5, then B5 would automatically record the
date this update occurred. in Worksheet code enter the following macro:

Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Range("A:A"), Target) Is Nothing Then
Exit Sub
End If
Application.EnableEvents = False
Target.Offset(0, 1).Value = Now()
Application.EnableEvents = True
End Sub

REMEMBER: Worksheet code.
 
G

Guest

Gary,
The macro works fine but there is any other way to set a date without
running a macro?
 
D

Dave Peterson

If you want a static date, you can select the cell and hit ctrl-; (control
semicolon).

If you want a static time, you can hit ctrl-:
 
G

Guest

Hello,

This works for me, but it has a side effect of not allowing any un-dos.
After changing the tracked cell, CTRL-Z does not do anything. Is there a way
to preserve the undo history?
 

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