There's more...

We can modify our NetWorkDays calculation to account for holidays as well. To do this, observe the following steps:

  1. Create the following table using an Enter Data query:

  1. Ensure that the Date column is flagged as having a data type of Date.
  2. Create a new measure with the following formula:
NetWorkDays2 = 
VAR __Date1 = MAX('R10_Table'[Created Date])
VAR __Date2 = MAX('R10_Table'[Finished Date])
VAR __Date1a = MINX( { __Date1, __Date2 },[Value])
VAR __Date2a = MAXX( { __Date1, __Date2 },[Value])
VAR __Calendar =
ADDCOLUMNS(
EXCEPT(
CALENDAR(__Date1a, __Date2a),
'R10_Holidays'
),
"__WeekDay",
WEEKDAY([Date],2)
)
RETURN
COUNTX(
FILTER(
__Calendar,
[__WeekDay] < 6
),
[Date]
)
  1. Place this NetWorkDays2 measure in the Table visualization created earlier.

The small change to the formula to account for holidays is to use the EXCEPT function to remove the dates in the R10_Holidays table from the calendar table that we create, __Calendar.