Thread: count only if
View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Fred Smith[_4_] Fred Smith[_4_] is offline
external usenet poster
 
Posts: 2,389
Default count only if

That's because Sumproduct does not support wildcards. You need to do it this
way:
=SUMPRODUCT(--(ISNUMBER(SEARCH("ray",MASTERLIST!E2:E100))),--(ISNUMBER(SEARCH("d",MASTERLIST!F2:F100))))

Regards,
Fred


"Erin" wrote in message
...
I tried (the critera is on worksheet named masterlist)...

=SUMPRODUCT(--(MASTERLIST!E2:E100="*Ray"),--(MASTERLIST!F2:F100="*d"))

but it doesn't work. :-(

"Erin" wrote:

How do I count the number of cells only if E1:E100 contains "ray" and
F1:F100
contains a "d"? I only want the "d's" in column if column E has Raytheon.
Right now it's counting all the "d's" in column f and all the "ray's" in
column e, but I only want column f to count if column e has ray. Hope
that
makes sense. Please help.