Weekdays between two dates in Excel?

E

Eric

Two solutions found online, two problems.

1) =NETWORKDAYS function should do the job, but I keep winding up with a
#NAME? error. (Using Excel 2003)

2) Formula suggestion, where A2 contains the earlier date and B2 contains
the later date:
=MAX(WEEKDAY(B2,2)-WEEKDAY(A2,2),0)+1+INT((B2-A2)/7)*5
gets hosed when one or both days are Saturday or Sunday
http://www.ozgrid.com/forum/showthread.php?t=65032

An explanation for 1), modification of 2) or other suggestion is
appreciated. TIA.
 
J

Jacob Skaria

--Using =NETWORKDAYS(). Incase this formula returns an error you need to
install ATP. To install; from menu Tools>AddIns> check 'Analysis ToolPak' and
hit OK.

=NETWORKDAYS(A1,B1)


--With startdate in A1 and end date in B1

=SUMPRODUCT(INT((B1-A1+WEEKDAY(A1-{2,3,4,5,6}))/7))


If this post helps click Yes
 
D

David Biddulph

Please read the Excel help entry for NETWORKDAYS.
--
David Biddulph

Eric said:
Two solutions found online, two problems.

1) =NETWORKDAYS function should do the job, but I keep winding up with a
#NAME? error. (Using Excel 2003)
....
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top