View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
pub pub is offline
external usenet poster
 
Posts: 29
Default sumproduct and weekday?

Ron Rosenfeld wrote in
:



I think you need to explain more clearly exactly what you are trying
to do. There are inconsistencies in what you write.

First of all, July 2008 (and any month for that matter) will have at
least four Fridays (not 2).

Also, you don't write what you want to happen if the value in D1:AH1
is less than 12. Your formula above ignores any results less than 12.

Your formula segment (a1+row(a1:a31)) will, with July 1 in A1, return
July 2 through Aug 1. So you will always be ignoring the first day of
the month. And if the month has less than 31 days ...

I don't understand why you expect to have a result of 14.

Here is what your formula is doing:

D1:AH1 is 31 entries
15 of them = 11
16 of them = 13

Subtracting 12 from each entry that is greater than 12, and summing
them, gives a result of 16. (Note that entries less than 12 are
evaluated to zero (0) in your formula).

During the 31 days that you are counting, which is July 2, 2008
through August 1, 2008 inclusive, there are five Fridays (July 4, 11 ,
18, 25 and August 1) and 26 non-Fridays. 26*16 = 416 which is the
result you are getting with your formula.

????
--ron


thanks,
if the machine runs 12 hours or less, then its running per manufacturer
specs. i filtered all those out. so i just need to see how much time
over 12 per month that we use it. i guess it breaks the machine or
something (im not much of an engineer).
and i realized my mistake on adding the date (i thought that would be the
easy part). i used every other day as an example.