ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   workday formula question (https://www.excelbanter.com/excel-discussion-misc-queries/186724-workday-formula-question.html)

notanexcelguru

workday formula question
 
I am trying to create a schedule for a machine. I know how much of a day
each job will take. When I use a formula to just add column b to c, the
result actually includes the hour of the day, but I need to exclude the
weekend. When I use workday function then the fraction of the day seems to
not be included in the calculation. Is there a way to combine these
functions to add a portion of a day only using the work week?






B C b+c workday function=WORKDAY(C3,B3)
3.25 5/1/08 12:00 AM 5/4/08 6:00 AM 5/6/08 12:00 AM


BoniM

workday formula question
 
=IF(OR(WEEKDAY(C3+B3)=7,WEEKDAY(C3+B3)=1),C3+B3+2, C3+B3)

Assuming you just wanted to add two more days if the finish date fell on the
weekend, this should give you what you want...

"notanexcelguru" wrote:

I am trying to create a schedule for a machine. I know how much of a day
each job will take. When I use a formula to just add column b to c, the
result actually includes the hour of the day, but I need to exclude the
weekend. When I use workday function then the fraction of the day seems to
not be included in the calculation. Is there a way to combine these
functions to add a portion of a day only using the work week?






B C b+c workday function=WORKDAY(C3,B3)
3.25 5/1/08 12:00 AM 5/4/08 6:00 AM 5/6/08 12:00 AM


notanexcelguru

workday formula question
 
It works. Thanks so much for your help. Do you know if there is a way to
omit holidays?

"BoniM" wrote:

=IF(OR(WEEKDAY(C3+B3)=7,WEEKDAY(C3+B3)=1),C3+B3+2, C3+B3)

Assuming you just wanted to add two more days if the finish date fell on the
weekend, this should give you what you want...

"notanexcelguru" wrote:

I am trying to create a schedule for a machine. I know how much of a day
each job will take. When I use a formula to just add column b to c, the
result actually includes the hour of the day, but I need to exclude the
weekend. When I use workday function then the fraction of the day seems to
not be included in the calculation. Is there a way to combine these
functions to add a portion of a day only using the work week?






B C b+c workday function=WORKDAY(C3,B3)
3.25 5/1/08 12:00 AM 5/4/08 6:00 AM 5/6/08 12:00 AM


BoniM

workday formula question
 
=WORKDAY(C3,B3,H1:H8)+B3-INT(B3)+C3-INT(C3)

I actually like this better than the if, anyhow... thanx for making me think!
Uses the workday function to add days and holidays, then takes the decimal
portion of both numbers to add the times and adds that to the days.
Just create your holiday range and substitute it for my H1:H8...


"notanexcelguru" wrote:

It works. Thanks so much for your help. Do you know if there is a way to
omit holidays?

"BoniM" wrote:

=IF(OR(WEEKDAY(C3+B3)=7,WEEKDAY(C3+B3)=1),C3+B3+2, C3+B3)

Assuming you just wanted to add two more days if the finish date fell on the
weekend, this should give you what you want...

"notanexcelguru" wrote:

I am trying to create a schedule for a machine. I know how much of a day
each job will take. When I use a formula to just add column b to c, the
result actually includes the hour of the day, but I need to exclude the
weekend. When I use workday function then the fraction of the day seems to
not be included in the calculation. Is there a way to combine these
functions to add a portion of a day only using the work week?






B C b+c workday function=WORKDAY(C3,B3)
3.25 5/1/08 12:00 AM 5/4/08 6:00 AM 5/6/08 12:00 AM



All times are GMT +1. The time now is 12:59 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com