View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
T. Valko T. Valko is offline
external usenet poster
 
Posts: 15,768
Default sumproduct by year??

You can't directly use wildcards in SUMPRODUCT.

This seems to be ok, except I'm gett ALL of the files
that were filed in 2007, not just the ones with the
ABCD prefix.


Your formula is counting all instances that *do not* start with the ABCD
prefix.

Try this:

=SUMPRODUCT(--(LEFT($C$2:$C$15403,4)<"ABCD"),--(YEAR($I$2:$I$15403)=2007))

--
Biff
Microsoft Excel MVP


"MDI Anne" wrote in message
...
I have a multi-columned worksheet, and am trying to pick out certain data.

One column has file names & the other has dates this file was submitted.
The formulas I'm using a
=SUMPRODUCT(--($C$2:$C$15403<"ABCD*"),(--(YEAR($I$2:$I$15403)=2007)))
where
"ABCD*" is the prefix for the file name. This seems to be ok, except I'm
gett ALL of the files that were filed in 2007, not just the ones with the
ABCD prefix.

Any help is appreciated...
Thanks!