View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Michael Link
 
Posts: n/a
Default Ignoring Dates in Sums

Between your reply and the other one just above, I'm on the right track. It's
actually kind of a relief that there wasn't some incredibly obvious solution
I was simply too stupid to know. Thanks!

"vezerid" wrote:

Cells formatted as date can be identified with the CELL(ref, "format")
formula. FOr example, if cell A2 contains 3-mar-06, then

=CELL(A2,"format")

will return "D1". All date format codes start with "D". Hence you can
use something like:

=SUMPRODUCT(A2:A100,--(LEFT(CELL(A2:A100,"format"),1)<"D"))

Does this help?

Kostis Vezerides