Unregistered
New Member
- Joined
- Mar 10, 2020
- Messages
- 2
- Office Version
- 2016
- Platform
- Windows
Hi all!
I'm new to this forum and I'm not quite an expert in VBA, but I'm trying.
I use this function to get the filedate time from a file:
This works pretty well, but the problem is as followings: the output is not a value. The above function overrrules the celltype; meaning changing the cell type to date won't work.
I would like to use the conditonal formatting to color the cells where =TODAY()-90. Due to the fact the output from the GetFileDate function isn't a date, it will not be affected.
What can I do to format the date as a value?
Thanks in advance!!
I'm new to this forum and I'm not quite an expert in VBA, but I'm trying.
I use this function to get the filedate time from a file:
VBA Code:
Function GetFileDateTime(R As Range)
Set R = R.Cells(1, 1)
GetFileDateTime = format(filedatetime(R.Value), "dd-mm-yyyy hh:nn")
End Function
This works pretty well, but the problem is as followings: the output is not a value. The above function overrrules the celltype; meaning changing the cell type to date won't work.
I would like to use the conditonal formatting to color the cells where =TODAY()-90. Due to the fact the output from the GetFileDate function isn't a date, it will not be affected.
What can I do to format the date as a value?
Thanks in advance!!