Time stamp cell range

jamada

Active Member
Joined
Mar 23, 2006
Messages
323
Hi, sorry I'm having difficulties with this, solutions appreciated very much.

I'm trying to time stamp Column "L" and effected rows with current date time (24hour clock)

LastRow = Range("A" & Rows.Count).End(xlUp).Row
For i = LastRow To 2 Step -1
If Cells(i, 3).Value > 0 Then
Range(Cells(i, 13)) = NumberFormat "MMMDD hh:mm".Value = Now()

End If
Next i

Tks Graham
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
Would it work if you changed the number format to;
Code:
Range(Cells(i, 13)) = Format(Now(), "MMMDD hh:mm")
 
Last edited:
Upvote 0
Hi BenGee, Thanks for the suggestion. Turns our my issue was using "Range", have corrected as follows.
Thank You!

LastRow = Range("A" & Rows.Count).End(xlUp).Row
For i = LastRow To 2 Step -1
If Cells(i, 3).Value > 0 Then
Application.EnableEvents = False
Cells(i, 13).Value = Now
Application.EnableEvents = True
End If
Next i

Application.CutCopyMode = False
 
Upvote 0

Forum statistics

Threads
1,223,705
Messages
6,173,991
Members
452,541
Latest member
haasro02

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