=IF(AND(K2>DATEVALUE("30062024"),K2<DATEVALUE("01702026")),"FY 25"),
the above statement returns #Value!, I expect it to return "FY 25" or false
=IF(AND(K2>DATEVALUE("30062024"),K2<DATEVALUE("01702026")),"FY 25"),
Expecting to get "FY 25" for the dates that falls into range or False for the Dates that falls out of range
=IF(AND(K2>DATEVALUE("30062024"),K2<DATEVALUE("01702026")),"FY 25"),
the above statement returns #Value!, I expect it to return "FY 25" or false
=IF(AND(K2>DATEVALUE("30062024"),K2<DATEVALUE("01702026")),"FY 25"),
Expecting to get "FY 25" for the dates that falls into range or False for the Dates that falls out of range
Share Improve this question asked Feb 3 at 9:32 Mwai.JohnMwai.John 275 bronze badges 5 |1 Answer
Reset to default 0DATEVALUE("30062024")
is not valid.
You might try DATEVALUE("30/06/2024"), but this means that your computer (regional settings) is based on the "DD/MM/YYYY" date formatting. In case you have another date formatting (like "YYYY/DD/MM", which is common in the USA), you might need another way to write your formula.
DATEVALUE("30062024")
is producing error.30062024
is not a valid date value. Datevalue function have to use like=DATEVALUE("01-JAN-2025")
or use date function likeDATE(2025,1,1)
. – Harun24hr Commented Feb 3 at 9:35K2
and what is your date range to compare. – Harun24hr Commented Feb 3 at 10:41