Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
NETWORKDAYS problem
I am using the NETWORKDAYS function to calculate the number of days between
2 dates. this is fine but i want to turn those days into weeks. i added "/4" to turn the counted days to whole five day weeks. But when i come to add a charge to those weeks, i get a wrong figure. i.e 01/01/05 - 31/01/05 = 4 weeks * £1 = £4.40. when it should be £4.00. is it networkdays formula thats making this error or me? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
NETWORKDAYS problem
On Sun, 21 Aug 2005 13:24:02 -0700, "Rick, United Kingdom"
wrote: I am using the NETWORKDAYS function to calculate the number of days between 2 dates. this is fine but i want to turn those days into weeks. i added "/4" to turn the counted days to whole five day weeks. But when i come to add a charge to those weeks, i get a wrong figure. i.e 01/01/05 - 31/01/05 = 4 weeks * £1 = £4.40. when it should be £4.00. is it networkdays formula thats making this error or me? The formula is doing exactly what you tell it to, but I don't understand how you get 4.40; given what you write, you should be getting 5.25. In any event, Networkdays assumes that Sat and Sun are weekend days and does not count them. It counts your starting day and your ending day. 1 Jan 2005 is a Saturday; 31 Jan 2005 is a Monday. Networkdays properly tells you there are 21 working days. But these are 5 day weeks; so you should divide the result by 5 and not by 4. Since your number is not evenly divisible by 5, the result is not 4 but rather 4.2. How you should handle this depends on how you wish to handle fractional weeks. And that you will have to post here. You can leave them as fractions, round up, or round down. --ron |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
NETWORKDAYS problem
That is because you are also getting a fraction.
Round it, either normal, or up or down =ROUND(A1,0) =ROUNDUP(A1,0) =ROUNDDOWN(A1,0) -- HTH RP (remove nothere from the email address if mailing direct) "Rick, United Kingdom" wrote in message ... I am using the NETWORKDAYS function to calculate the number of days between 2 dates. this is fine but i want to turn those days into weeks. i added "/4" to turn the counted days to whole five day weeks. But when i come to add a charge to those weeks, i get a wrong figure. i.e 01/01/05 - 31/01/05 = 4 weeks * £1 = £4.40. when it should be £4.00. is it networkdays formula thats making this error or me? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Using Networkdays function problem | Excel Discussion (Misc queries) | |||
networkdays problem | Excel Worksheet Functions | |||
NETWORKDAYS function problem | Excel Worksheet Functions | |||
networkdays() problem when deleting row or column | Excel Worksheet Functions | |||
Networkdays problem | Excel Worksheet Functions |