Adding days to a date, but excluding weekends & pub holidays

Zabman

Board Regular
Joined
Apr 7, 2010
Messages
77
Hi,

I am trying to develop a formula that adds 3 working days to a formula if the date stamp is after 10am, and 2 days if it is before. The cell containing the time I want to modify is E2. I have the following, but cannot work out how to rule out the weekends! I am sure networkdays is the way to go due to the public holiday factor, but just cant get my head around it!

=IF(MOD(E2,1)>0.41667,INT(E2) + 3,INT(E2) + 2)
 

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN
Hi,

I am trying to develop a formula that adds 3 working days to a formula if the date stamp is after 10am, and 2 days if it is before. The cell containing the time I want to modify is E2. I have the following, but cannot work out how to rule out the weekends! I am sure networkdays is the way to go due to the public holiday factor, but just cant get my head around it!

=IF(MOD(E2,1)>0.41667,INT(E2) + 3,INT(E2) + 2)
Use the WOKDAY function...

=WORKDAY(E2,IF(HOUR(E2)>10,3,2),A1:A10)

Where A1:A10 is the list of holiday dates.

Note that the WORKDAY function requires the Analysis ToolPak add-in be installed if you're using a version of Excel prior to Excel 2007. If you enter the formula and get a #NAME? error look in Excel help for the WORKDAY function. It'll tell you how to fix the problem.
 
Last edited:
Upvote 0
Thanks for that. I had looked at that function, but ruled it out due to the public holiday thing, its quite important that holidays are excluded the same as weekends. Am I missing something with the weekday function?
 
Upvote 0
Thanks for that. I had looked at that function, but ruled it out due to the public holiday thing, its quite important that holidays are excluded the same as weekends. Am I missing something with the weekday function?
WORKDAY does have a holidays argument.

I think you're confusing the WEEKDAY function with the WORKDAY function.
 
Upvote 0

Forum statistics

Threads
1,224,594
Messages
6,179,792
Members
452,942
Latest member
VijayNewtoExcel

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