Automated timestamp update not working

CeJe

New Member
Joined
Aug 15, 2020
Messages
1
Office Version
  1. 2013
Platform
  1. Windows
Hi!

Wanted outcome:
- When I make a change in any cell in column B to W, I want a timestamp in column X, same row, that automatically reflects the date of this latest change.

I'd prefer to use a formula instead of VBA, as I would like to still be able to use the undo function.

Problems encountered so far:
- The formula that has given me the best results so far is =IF(B4<>"",IF(X4<>"",X4,TODAY()),"") - copy pasted from a page I found searching around for a solution.
However...
1) Written like this, the timestamp only auto updates if there is a change in column B - I would like it to auto update based on changes made in any column from B to W.
2) I have already filled out all cells in my data sheet... But when I test the formula on a row that is already filled out, the timestamp returns 00 January 1900 - even after I change the value in column B. I understand that the timestamp function doesn't know when I first filled out the cell, but I would expect it to update the date when I change the value today. I have tried testing the formula in a completely empty sheet, where I first write the formula in column X and then enter a value in column B. Here the formula works fine and returns 15 August 2020.

I've tried about 20+ different ways (both formulas and VBAs), but for reasons I do not know, it hasn't worked for me (I'm new to this, so I can't figure out the mistakes by myself)...

Hopefully one of you understands my question and knows how to help :)
 

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.
I think your best bet would be a worksheet_change event. Copy and paste this macro into the worksheet code module. Do the following: right click the tab name for your sheet and click 'View Code'. Paste the macro into the empty code window that opens up. Close the code window to return to your sheet. Enter a value in B:W and press the RETURN key.
VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
    If Intersect(Target, Range("B:W")) Is Nothing Then Exit Sub
    Range("X" & Target.Row) = Date
End Sub
 
Upvote 0

Forum statistics

Threads
1,214,983
Messages
6,122,583
Members
449,089
Latest member
Motoracer88

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top