Can I have revision date auto inserted when excel file is changed

  • Thread starter Thread starter BJacobi
  • Start date Start date
B

BJacobi

I am looking for a function or formula that will automatically insert a date
when I revise a document that will be saved and visible to anyone that
accesses that file in the future. The file will be revised periodically and i
will not need a history, rather the last revision date.
 
Hi,

You could use the built in document property. Put this in the 'before_save
event

sheets("Sheet1").Range("A1").Value = _
ActiveWorkbook.BuiltinDocumentProperties("last save time")

Mike
 
Press ALT F11 to open the VBA editor. There, go to the Insert menu,
choose Module, and paste the following code into that module.

Function LastSavedDate() As Date
LastSavedDate = FileDateTime(ThisWorkbook.FullName)
End Function

Close the VBA editor and return to Excel. In the cell in which you
want the last saved time to appear, enter

=LastSavedDate()

This will return the date and time of the last save operation.

Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group, 1998 - 2009
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)
 
Mac?

I am using Office for Mac 2011 and can not get the formula to work, any suggestions? As I inserted the VBA module, but nothing?
 
Back
Top