No Error In Formula Syntax Though Field Is Empty

• 0
• Question
• Updated 2 years ago
I'm using the following formula:

```If(DayOfWeek([Date of Injury])=6, [Date of Injury] + Days(11) - Today(),
DayOfWeek([Date of Injury])=0, [Date of Injury] + Days(10) - Today(), [Date of Injury] + Days(9) - Today())```
﻿[Date Of Injury] is a date field. Essentially, there are 7 business days to make a phone call from the [Date of Injury]. So this formula is to do a countdown for the days left to call. If [Date Of Injury] is a Saturday or Sunday the countdown begins on Monday. Though, even when the [Date Of Injury] Field is filled in this calculated field is remaining blank.
• 1,644 Points

Posted 2 years ago

• 0
• 70,384 Points
What field type is this field. Is it a formula duration field?
• 1,644 Points
It is a numeric Formula
• 70,384 Points
Then wrap the whole thing in "ToDays" and see if it works

ToDays(
`If(DayOfWeek([Date of Injury])=6, [Date of Injury] + Days(11) - Today(), `
DayOfWeek([Date of Injury])=0, [Date of Injury] + Days(10) - Today(),

[Date of Injury] + Days(9) - Today())

)
• 1,644 Points
This did it! Thank you!
• 70,384 Points
Ideally, it should have given you a syntax error.  You were calculating a Duration, but the field type was numeric.