Problem with formula

one_more_cave_dweller

Board Regular
Joined
Sep 27, 2004
Messages
118
:oops:
I want cell a20 to return the value of cells c1:c10 but only if cells d1:d10 contain a value. I tried =SUMIF(d$1:$d$10,">0",$c$1:$c$10) but that will not work if d1:d10 contains a negative number. I also tried =SUMIF(d$1:$d$10,"<>0",$c$1:$c$10) but that returns values from a1:a10 and b1:b10 also. How can I get it to pick up either positive or negative numbers for only c1:c10?

Thanks :pray:
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().

vconfused

Well-known Member
Joined
Jun 11, 2004
Messages
547
So, as long as there is a number in any cell from D1 to D10, then we want to sum whatever is in C1 through C10?

Or do we only want to sum the numbers in C1 throuth C10 only if there is something in the same row in D10?
 

Tazguy37

MrExcel MVP
Joined
May 28, 2004
Messages
4,237
Maybe this?:
=SUMIF(D$1:$D$10,"<>",$C$1:$C$10)

Hope that helps!
 

Forum statistics

Threads
1,147,677
Messages
5,742,566
Members
423,738
Latest member
AshleyKitsune

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top