Hi,

I found this vba code

Function FileCountDate(Path As String, FileType As String) As Long


Dim strTemp As String
Dim lngCount As Long


Application.Volatile

strTemp = Dir(Path & FileType)
Do While strTemp <> ""
If Format(FileDateTime(Path & strTemp), "dd.mm.yyyy") = "03/04/2019" Then
lngCount = lngCount + 1
End If
strTemp = Dir
Loop
FileCountDate = lngCount

End Function

which works fine, how can I change the code instead of "03/04/2019" to use today's date, so each day when I open the file I will not have to modify the date, I have tried few things but I have not managed to make it work.

Please let me know.

Thank you.