If exceed 24 hours show “23:59:59”
Question
So I got this calculated column called "Due time" with this format in it:
=IF([Hours]<24&&[Minutes]<60;CONCATENATE([Hours]&":";[Minutes]);"23:59:59")
I only get syntax error with this, can someone help me?
No correct solution
OTHER TIPS
Assuming your Hours
and Minutes
columns are of number type.
Try Using below formula:
=IF(AND([Hours]<24, [Minutes]<60); CONCATENATE([Hours], ":", [Minutes]); "23:59:59")
Note:
- Sometimes comma(
,
) does not work in formula (I am not sure but it is based on something language or regional settings on your site). So in that case use semicolon(;
) instead of comma(,
). - Return your calculated field as Single line of text.
official documentation: Calculated Field Formulas.
If I'm not mistaken, it's the semi-colons - they should be commas:
=IF([Hours]<24&&[Minutes<60,CONCATENATE([Hours]&":",[Minutes]),"23:59:59")
Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange