How to automatically update the Excel file editing time
If working in a team when processing Excel documents, the content of the file will be edited many times, with different times. To control and manage the contents of an Excel file or to know when the other person last edited the file, you can insert the automatic update time into Excel. Then information about the time of creating, editing the latest Excel file is recorded and displayed right in the Excel file, helping you to know the last date the content was changed. The following article will guide you how to update the last time you edited an Excel file.
Instructions for updating the Excel file editing time
Step 1:
First of all we open the Excel file we want to add the edited time to the content. Press the key combination Alt + F11 to open the VBA code editor.
At Microsoft Visual Basic for Applications interface, click Insert and then select Module as shown below.
Step 2:
Then you enter the following code into the interface.
Sub Workbook_Open() Range("A21").Value = Format(ThisWorkbook.BuiltinDocumentProperties("Creation Date"), "short date") Range("B21").Value = Format(ThisWorkbook.BuiltinDocumentProperties("Last Save Time"), "short date") End Sub
Note A1 and B1 are the position of the two cells where the creation time and the last time Excel file was modified. This position can vary depending on where the user sets the time in the Excel data table.
Once you have entered the code, click the Run icon to run.
Finally, at the position of the 2 cells you selected will display the time of the Excel file created and the time to edit the Excel file. Time display can completely change the format if desired.
See more:
- Instructions on how to insert current date in Excel
- How to format dates in Excel
- How to insert the current time into Google Sheets
I wish you successful implementation!
You should read it
- How to fix date errors when copying to another Excel file
- Instructions on how to insert the current date in Excel
- How to fix the date #VALUE error in Excel
- Date time functions in Excel
- Instructions on how to fix reverse dates in Excel
- Forgot password protected Excel file, what should you do?
- Quickly insert current date and time into a cell in Excel
- Instructions for inserting a PDF file into Excel spreadsheet
- Excel date function - Usage and examples
- Change the slash to a dot in Excel format
- How to arrange incremental dates in Excel
- NOW function - The function returns the current date and time in Excel
Maybe you are interested
Difference between function and formula in Excel
8 little-known Excel functions that can save you a lot of work
How to use pictures as Excel chart columns
6 ways to fix arrow keys not working in Excel
Fix the error of not being able to use the F4 key in Excel with shortcut keys
How to split sheet into multiple separate Excel files