Tag Archives: how to add in a cell last time modified

Add created date and last modified time in a cell in Excel

If you want to add the last save time and/or creation date in Excel cells follow this steps (via VBA scripts):

date

1. Hold ALT + F11 keys, that will open the Microsoft Visual Basic for Applications window:

2. Click Insert > Module, and paste the following macro in the Module Window:

Sub Workbook_Open()
Range(“A1”).Value = Format(ThisWorkbook.BuiltinDocumentProperties(“Creation Date”), “short date”)
Range(“B1”).Value = Format(ThisWorkbook.BuiltinDocumentProperties(“Last Save Time”), “short date”)
End Sub

3. Press F5 key to run the macro.

Then it inserts the created date in Cell A1, and inserts the last modified date in Cell B1.
(you can modify the cells by simply editing the script and replacing A1,B1 with the desired cells)

Enjoy !