Forum Discussion
Date stamp for modified cells
hi.
ive tried google for answers and just getting confused! i am creating a spreadsheet in which there is a specific column i want to track the changes of by time/date stamp. ie, data goes into column E (Say cell 12) and the 'Last modified date" would appear in F12 along side it. ive tried this code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Target, Range("E1:E1000")) Is Nothing Then Exit Sub
Target.Offset(0, 2) = Now()
End Sub
It works GREAT!! i right click the sheet tab, select VEIW CODE, then paste it. its sweet!! but it doesnt stay there..so next time i open the sheet, the date stamps are there in col. F but when i change a cell in col. E the time stamps dont change...if i leave excel open for 24hrs, the stamp changes fine! so there seems to be a little problem here hey? its excell 2013. what do I do? is there an easier formula to type in instead? or is there a way to save the code so it stays put?
Jake
1 Reply
- JKPieterseSilver Contributor
Hi Jake,
Paste in your code on last time and then Save-as the file and select the file type Excel Macro-Enabled Workbook (xlsm).