View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Claus Busch Claus Busch is offline
external usenet poster
 
Posts: 3,872
Default Can you "Time Stamp" in Excel?

Hi,

Am Wed, 15 Apr 2015 11:19:05 -0700 (PDT) schrieb :

Cell L115 is blank. I would like cell M115 to have the time stamp. If I type an x in cell L115, I would like cell M115 to show 04/15/15. Even if I open the file tomorrow I would still want M115 to show 4/15/15. Thanks.


right click on the sheet tab = Show Code and insert following code into
the code window of the sheet:

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address < "$L$115" Then Exit Sub

With Target.Offset(, 1)
If Target = "x" Then .Value = Date
.NumberFormat = "MM/DD/YY"
End With
End Sub


Regards
Claus B.
--
Vista Ultimate / Windows7
Office 2007 Ultimate / 2010 Professional