select multiple ranges in formula

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm trying to select a bunch of ranges of data as a single argument in a
formula. I select the first range (ie, C2:C20), but when I select the second
range (ie, C24:C42), it automatically puts a comma, and the formula treats
this as the next argument. Is there a way to group all of the ranges I'm
selecting?

My specific task is =SUMIF( C2:C20,C24:C42 , D2 , E2:E20,E24:E42)

Thanks for the help.
 
try
=SUMPRODUCT(SUMIF(INDIRECT({"C2:c20","c24:c42"}),D2,INDIRECT({"e2:e20","e24:e42"})))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top