ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   How do I show the date of an update? (https://www.excelbanter.com/excel-worksheet-functions/96361-how-do-i-show-date-update.html)

Odonata

How do I show the date of an update?
 
I'm trying to find a way to automatically show the date a cell is updated.
I'm creating a status report where column A contains text that is updated
frequently. I would like to find a way for column B to show a date of the
most recent update to the column A cell.

This is not the date the spreadsheet is updated, but just the cell in
question.
Thanks!

Ardus Petus

How do I show the date of an update?
 
Paste following code into your worksheet's code page
(right-click worksheet's tab, select View code)

'----------------------------------------------------------------------------------------
Private Sub Worksheet_Change(ByVal Target As Range)
Dim rRange As Range
Dim rcell As Range

Set rRange = Intersect(Target, Columns("A"))
If Not rRange Is Nothing Then
For Each rcell In rRange
rcell.Offset(0, 1) = Now
Next rcell
End If

End Sub

'----------------------------------------------------------------------------------------

HTH
--
AP

"Odonata" a écrit dans le message de
news: ...
I'm trying to find a way to automatically show the date a cell is updated.
I'm creating a status report where column A contains text that is updated
frequently. I would like to find a way for column B to show a date of the
most recent update to the column A cell.

This is not the date the spreadsheet is updated, but just the cell in
question.
Thanks!





All times are GMT +1. The time now is 02:41 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com