Hi Experts
How would you write a measure to return the number of WorkingDaysPassed for Oct 18 from the table shown. I want to add the measure to a matrix table..
Solved! Go to Solution.
Hi @Route11,
You can try to use below measure to calculate remain working day based on today function and table date column:
Remain Working days = IF ( TODAY () > ENDOFMONTH ( 'Sample'[Date] ), 0, IF ( FORMAT ( TODAY (), "mm/yyyy" ) = FORMAT ( ENDOFMONTH ( 'Sample'[Date] ), "mm/yyyy" ), COUNTROWS ( FILTER ( CALENDAR ( TODAY (), ENDOFMONTH ( 'Sample'[Date] ) ), NOT ( WEEKDAY ( [Date], 1 ) IN { 1, 7 } ) ) ), COUNTROWS ( FILTER ( CALENDAR ( STARTOFMONTH ( 'Sample'[Date] ), ENDOFMONTH ( 'Sample'[Date] ) ), NOT ( WEEKDAY ( [Date], 1 ) IN { 1, 7 } ) ) ) ) )
Regards,
Xiaoxin Sheng
Hi @Route11,
You can try to use below measure to calculate remain working day based on today function and table date column:
Remain Working days = IF ( TODAY () > ENDOFMONTH ( 'Sample'[Date] ), 0, IF ( FORMAT ( TODAY (), "mm/yyyy" ) = FORMAT ( ENDOFMONTH ( 'Sample'[Date] ), "mm/yyyy" ), COUNTROWS ( FILTER ( CALENDAR ( TODAY (), ENDOFMONTH ( 'Sample'[Date] ) ), NOT ( WEEKDAY ( [Date], 1 ) IN { 1, 7 } ) ) ), COUNTROWS ( FILTER ( CALENDAR ( STARTOFMONTH ( 'Sample'[Date] ), ENDOFMONTH ( 'Sample'[Date] ) ), NOT ( WEEKDAY ( [Date], 1 ) IN { 1, 7 } ) ) ) ) )
Regards,
Xiaoxin Sheng
Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!
User | Count |
---|---|
441 | |
196 | |
109 | |
56 | |
49 |
User | Count |
---|---|
478 | |
240 | |
135 | |
76 | |
74 |