CALDAYS
CALDAYS(from, to)
The number of calendar days between two dates, weekends and holidays included, such as how many days are left until a milestone. It counts whole days, ignoring the time of day, and gives a plain number, negative when to is before from.
Arguments
| Argument | What to give it |
|---|---|
| from | A date, like DATADATE() or [Start date]. Blank gives blank. |
| to | A date. Blank gives blank. |
Examples
Formula=CALDAYS(DATADATE(), [Finish date])
How many calendar days from the data date until the task finishes.
Formula=CALDAYS([Finish date], [Constraint date]) < 0
TRUE when the task finishes after its constraint date; blank when it has no constraint date.
Measure (on the project)=CALDAYS(DATADATE(), [Finish date])
As a measure: calendar days from the data date to the end of the project.
Reach for something else when
| You want | Use |
|---|---|
| Working time on the task's calendar | WORKDAYS |
| The date some days later | ADDWORK, naming a calendar that works every day: ADDWORK([Finish date], 5, "7-day") |
| Today's date as one end | TODAY |
Common questions
Why can't I subtract two dates instead?
The editor refuses it, because it could mean working time or calendar days: Subtracting two dates is ambiguous. Use WORKDAYS(from, to) for working time or CALDAYS(from, to) for calendar days.
Can I give CALDAYS a calendar?
No: calendar days don't depend on a calendar. For working time on a named calendar, use WORKDAYS(from, to, "6-day").
