Number of day

Tom.Jones

Well-known Member
Joined
Sep 20, 2011
Messages
509
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
  2. Mobile
Howdy,

Need to find number of working day between 2 date, for every quarter.
In A2 start date
In B2 end date
In C2 Q1 quarter 1
In D2 Q2 quarter 2
In E2 Q3 quarter 3
In F2 Q4 quarter 4

Start date | end date | Q1 | Q2 | Q3 | Q4
Need how many working day are in Q1 - Q4 for date between start date and end date.
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
Please try this

Book1
CDEFGH
2StartEndQ1Q2Q3Q4
31/15/20234/15/2023761500
44/2/20236/1/202306000
54/2/202310/18/20230899018
64/2/20236/1/202306000
Sheet1
Cell Formulas
RangeFormula
E3E3=MAX(DAYS360(MAX($C3,DATE(YEAR($C3),1,1)),MIN(EOMONTH(DATE(YEAR($C3),3,1),0)+1,$D3+1)))
F3:F6F3=MAX(DAYS360(MAX($C3,DATE(YEAR($C3),4,1)),MIN(EOMONTH(DATE(YEAR($C3),6,1),0)+1,$D3+1)),0)
G3:G6G3=MAX(DAYS360(MAX($C3,DATE(YEAR($C3),7,1)),MIN(EOMONTH(DATE(YEAR($C3),9,1),0)+1,$D3+1)),0)
H3:H6H3=MAX(DAYS360(MAX($C3,DATE(YEAR($C3),10,1)),MIN(EOMONTH(DATE(YEAR($C3),12,1),0)+1,$D3+1)),0)
E4:E6E4=MAX(DAYS360(MAX($C4,DATE(YEAR($C4),1,1)),MIN(EOMONTH(DATE(YEAR($C4),3,1),0)+1,$D4+1)),0)
 
Upvote 0
See if the following formula works for you:
Excel Formula:
=MAX(0,NETWORKDAYS(MAX($A2,DATE(YEAR($A2),RIGHT(C$1)*3-2,1)),MIN($B2,DATE(YEAR($A2),RIGHT(C$1)*3+1,0)),Holidays))
where Holidays is a named range containing holiday dates.
 
Upvote 0
Solution

Forum statistics

Threads
1,216,008
Messages
6,128,256
Members
449,435
Latest member
Jahmia0616

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top