ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Creating and transit time excel formula (https://www.excelbanter.com/excel-discussion-misc-queries/160642-creating-transit-time-excel-formula.html)

Neal C

Creating and transit time excel formula
 
When I create a transit time sum it includes the weekends as it calculates
the time between 2 dates/time. Can anyone help and advise on how I can add to
my sum to minus the weekends?
Thanks
Neal

David Biddulph[_2_]

Creating and transit time excel formula
 
May be worth looking at the NETWORKDAYS function?
--
David Biddulph

"Neal C" <Neal wrote in message
...
When I create a transit time sum it includes the weekends as it calculates
the time between 2 dates/time. Can anyone help and advise on how I can add
to
my sum to minus the weekends?
Thanks
Neal




Pete_UK

Creating and transit time excel formula
 
If you use the WEEKDAY function on a date it will return 5 for a
Friday and 1 for Monday. Perhaps you can check for these and subtract
48 hours if your dates return these values.

Hope this helps.

Pete

On Oct 3, 3:59 pm, Neal C <Neal wrote:
When I create a transit time sum it includes the weekends as it calculates
the time between 2 dates/time. Can anyone help and advise on how I can add to
my sum to minus the weekends?
Thanks
Neal




Neal C

Creating and transit time excel formula
 
I looked at network days but it with this formula I would have to list the
weekends. I was looking for an 'IF, AND, OR' sum but I'm not sure this will
work?


"David Biddulph" wrote:

May be worth looking at the NETWORKDAYS function?
--
David Biddulph

"Neal C" <Neal wrote in message
...
When I create a transit time sum it includes the weekends as it calculates
the time between 2 dates/time. Can anyone help and advise on how I can add
to
my sum to minus the weekends?
Thanks
Neal





David Biddulph[_2_]

Creating and transit time excel formula
 
Perhaps I've misunderstood what you're trying to do. I assumed that you had
calculated the difference between 2 times, and got a time period which
included weekends. You now wanted to exclude weekend time from that. Won't
the difference between (INT(end_date)-INT(start_date)) and
(NETWORKDAYS(start_date,end_date)-1) be the number of weekend days which you
are trying to exclude? Where do you "have to list the weekends"?

[There may, of course, be confusion if you are starting and/or finishing
your interval at a weekend, but you haven't specified how you want to treat
such situations. In that situation you may want to invoke the WEEKDAY
function to adjust the answer.]
--
David Biddulph

"Neal C" <Neal wrote in message
...
I looked at network days but it with this formula I would have to list the
weekends. I was looking for an 'IF, AND, OR' sum but I'm not sure this
will
work?


"David Biddulph" wrote:

May be worth looking at the NETWORKDAYS function?
--
David Biddulph

"Neal C" <Neal
wrote in message
...
When I create a transit time sum it includes the weekends as it
calculates
the time between 2 dates/time. Can anyone help and advise on how I can
add
to
my sum to minus the weekends?
Thanks
Neal








All times are GMT +1. The time now is 02:14 AM.

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