VBA EXCEL - Find the oldest date in a column

Viewed 7407

Currently working on a function, and as part of it i need to find the oldest date in a column in VBA. Have spent a while looking for solutions but cant find much. I found one line however it doesn't actually work. Ill post the code snippet I have but any suggestions or solutions would be greatly appreciated!

Public Function SetSOWDates() As String

    Dim wsCRC As Worksheet
    Set wsCRC = Worksheets("CRC")

    Dim LastRowInCRC As Long

    LastRowInCRC = CRC.LastRowInCRC()

    LatestDate = Format(wsCRC.Max(Range("K8:K" & LastRowInCRC)), "dd/mm/yyyy")

    Debug.Print LatestDate

End Function
2 Answers
Related