1. ## NetWorkDays (Excel 2003)

Hi

Pls advise how do I set the weekend days as Friday & Saturday instead of Saturday & Sunday
I have look at the Help but is unable to figure out holidays' part in the function.
Syntax : NETWORKDAYS(start_date,end_date,holidays)

TIA

regards, francis

2. ## Re: NetWorkDays (Excel 2003)

As far as I know, the function only treats actual weekends (Sat/Sun) as weekends and it can not be changed. Do you have the option of treating all days as one day ahead? This could work.

The "holiday" part is a range of cells containing the dates that should be ignored by the networkdays. [If you work one day in the past to get Fri/Sat to be defined as weekends, you must define all the dates 1 day ahead as well]

Steve

3. ## Re: NetWorkDays (Excel 2003)

Hi Francis

Try:

= NETWORKDAYS(A1,B1+1)-1

Where A1 is the start date and B1 the end date

4. ## Re: NetWorkDays (Excel 2003)

Steve's suggestion of shifting all dates by 1 is the easiest solution.

If you wish, you could use the series of functions provided at Date/Time: Doing WorkDay Math in VBA. You don't have to understand the code, the only thing you'd need to do is change one line in the IsWeekend function:

Case vbSaturday, vbSunday

should become

Case vbFriday, vbSaturday

to count Friday and Saturday as weekend days.

5. ## Re: NetWorkDays (Excel 2003)

If you don't work with the offset days but with the actual days, wouldn't it be:
= NETWORKDAYS(A1+1,B1+1)

[Though they may give equivalent results...]

and the range for the holiday list would be each of the holidays +1 ?

Steve

6. ## Re: NetWorkDays (Excel 2003)

Hi Steve

I am just scratching my head to see the difference....I may have missed your point!

I seem to get the same result with both Functions, see attached.

7. ## Re: NetWorkDays (Excel 2003)

Your number will be 1 less than mine if the Startdate is on a real weekend date. While presuming a Saturday might not be a startdate (since it is weekend in both schemes), a Sunday is not a weekend in the proposed system and would be a valid startdate. Your scheme still treats it as a weekend since you don't adjust it by 1 day...

Steve

8. ## Re: NetWorkDays (Excel 2003)

Thanks Steve, all my little tests and that is the one I didn't do <img src=/S/blush.gif border=0 alt=blush width=15 height=15>

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•