Display last date workbook was modified?

G

Guest

I would like to have a cell display the last date a workbook was modified.
What would the code for that be?

Thanks in advance for any help.
 
M

mrice

You could use a Worksheet_change or Workbook_beforesave macro to
populate a cell with the current date/time.

e.g.

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
Sheets(1).Cells(1, 1) = Date
End Sub

pasted into the thiswokbook tab in the VBA editor (Shift F11)
 

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