View Single Post
 
Old 12-03-2019, 02:07 PM
PrincessApril PrincessApril is offline Windows 10 Office 2019
Competent Performer
 
Join Date: Nov 2019
Posts: 102
PrincessApril is on a distinguished road
Default

Quote:
Originally Posted by NoSparks View Post
Are you trying to use that code for the sheet pictured in post #16, where the dates are in column G ?
I've moved things around. Attached is a screenshot of the current working version. Target column is now E and first cell is E6 (right now it doesn't seem to work anymore--no runtime error or anything just doesn't seem to process. I have macros enabled).


Code:
Sub UpdateIntakeDate()
    Dim rng As Range, cel As Range, lr As Long
With Sheets("Client Tracker")
    lr = .Cells(.Rows.Count, "E").End(xlUp).Row
    If lr < 12 Then Exit Sub
    Set rng = .Range("E6:E" & lr)
    For Each cel In rng
        If cel <> "" Then
            If Date >= DateAdd("yyyy", 1, cel) Then
               cel = DateSerial(Year(Date), Month(cel.Value), Day(cel.Value))
            End If
        End If
    Next cel
End With
End Sub
Attached Images
File Type: png tracker ss updated.png (33.3 KB, 9 views)
Reply With Quote