Entries

Days Left V1

dateBetween(prop("Due date"), now(), "days")

Days Left V2

if(empty(prop("Due date")) or round(dateBetween(prop("Due date"), now(), "hours")) <= 0, toNumber(""), round(dateBetween(prop("Due date"), now(), "hours") / 24 * 10) / 10)

if(empty(prop("Due date")) or round(dateBetween(prop("Due date"), now(), "hours")) <= 0,

Checks to see if Due date is empty or the number of hours between the current date and the Due Date is less than or equal to 0.

toNumber(""),

If either are true, it converts a blank result to a number, which returns a blank cell instead of a 0.

dateBetween(prop("Due date"), now(), "hours") / 24

If either are untrue, it takes the number of hours between the current date and the Due Date and divides it by 24 to get the number of days to a decimal place.

round( ... * 10) / 10

This takes the result from the section above and multiplies it by 10 and then rounds it. It then divides it by 10 to move the decimal place back one place.

<aside> <img src="https://s3-us-west-2.amazonaws.com/secure.notion-static.com/1649d2f9-1b45-478a-86b4-341fbe27e06f/benny.png" alt="https://s3-us-west-2.amazonaws.com/secure.notion-static.com/1649d2f9-1b45-478a-86b4-341fbe27e06f/benny.png" width="40px" /> By BenLatest • Was this helpful? Please consider buying me a coffee. Cheers!

</aside>