ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Sumproduct IF Q (https://www.excelbanter.com/excel-worksheet-functions/130640-sumproduct-if-q.html)

Sean

Sumproduct IF Q
 
I wish to Sumproduct Col B x D (from rows 5 to 10) but only if the
Value in Col M5:10 = Cars

So I could have a scenario of

ColB5 x ColD5 +
ColB7 x ColD7 +
ColB8 x ColD8 +
ColB10 x ColD10 =

As M6 & M9 were not = Cars, then I ignored them from my Calculation

Thanks


Ron Coderre

Sumproduct IF Q
 
Try this:

=SUMPRODUCT(B5:B10,D5:D10,--(M5:M10="Cars"))
or
=SUMPRODUCT(B5:B10*D5:D10*(M5:M10="Cars"))


Does that help?
***********
Regards,
Ron

XL2002, WinXP


"Sean" wrote:

I wish to Sumproduct Col B x D (from rows 5 to 10) but only if the
Value in Col M5:10 = Cars

So I could have a scenario of

ColB5 x ColD5 +
ColB7 x ColD7 +
ColB8 x ColD8 +
ColB10 x ColD10 =

As M6 & M9 were not = Cars, then I ignored them from my Calculation

Thanks



Bob Phillips

Sumproduct IF Q
 
=SUMPRODUCT(--(M5:M10="Cars"),(D5:D10-B5:B10))

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Sean" wrote in message
ups.com...
I wish to Sumproduct Col B x D (from rows 5 to 10) but only if the
Value in Col M5:10 = Cars

So I could have a scenario of

ColB5 x ColD5 +
ColB7 x ColD7 +
ColB8 x ColD8 +
ColB10 x ColD10 =

As M6 & M9 were not = Cars, then I ignored them from my Calculation

Thanks




Sean

Sumproduct IF Q
 
On Feb 14, 12:27 pm, "Bob Phillips" wrote:
=SUMPRODUCT(--(M5:M10="Cars"),(D5:D10-B5:B10))

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"Sean" wrote in message

ups.com...



I wish to Sumproduct Col B x D (from rows 5 to 10) but only if the
Value in Col M5:10 = Cars


So I could have a scenario of


ColB5 x ColD5 +
ColB7 x ColD7 +
ColB8 x ColD8 +
ColB10 x ColD10 =


As M6 & M9 were not = Cars, then I ignored them from my Calculation


Thanks- Hide quoted text -


- Show quoted text -


Thanks guys it works a treat


Bob Phillips

Sumproduct IF Q
 
Sorry, I read that as D-B for some reason

=SUMPRODUCT(--(M5:M10="Cars"),D5:D10,B5:B10)

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Bob Phillips" wrote in message
...
=SUMPRODUCT(--(M5:M10="Cars"),(D5:D10-B5:B10))

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my
addy)



"Sean" wrote in message
ups.com...
I wish to Sumproduct Col B x D (from rows 5 to 10) but only if the
Value in Col M5:10 = Cars

So I could have a scenario of

ColB5 x ColD5 +
ColB7 x ColD7 +
ColB8 x ColD8 +
ColB10 x ColD10 =

As M6 & M9 were not = Cars, then I ignored them from my Calculation

Thanks







All times are GMT +1. The time now is 10:02 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com