SUMIF blank cells containing formula

Charmwah

Board Regular
Joined
Jan 23, 2017
Messages
64
Hi all

Probably a very simple answer, but I have a series of SUMIF cells which all work perfectly, until they reach a blank cell which contains a formula. I can't find the right syntax for the SUMIF to work, any ideas? The code at present is:

Code:
=SUMIF($AI$2:$AI$328,"",$AD$2:$AD$328)

Where column AI is the range to check, and column AD is the number to count if the criterion is met.

Kind regards

Dave
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
Zeroes or empty cells should not hurt SUMIF equations (adding zero to any value does not change it).
So it shouldn't be necessary to filter them out.

If you really want to COUNT the cells, and not SUM them, you would use COUNTIF, not SUMIF.

If you need help getting it to work, please clarify what exactly is in these cells that you are trying to Count or Sum, and that the formula that returns the values in those cells looks like.
 
Upvote 0
Hi Joe4

The cells are blank, not zeros. The formula thats inside each cell is an IF statement that analyses some adjacent columns, returning a priority value when two columns are populated:

Code:
=IF(AH2="",AF2,AH2)

Thanks

Zeroes or empty cells should not hurt SUMIF equations (adding zero to any value does not change it).
So it shouldn't be necessary to filter them out.

If you really want to COUNT the cells, and not SUM them, you would use COUNTIF, not SUMIF.

If you neeH263="",AF263,AH263)d help getting it to work, please clarify what exactly is in these cells that you are trying to Count or Sum, and that the formula that returns the values in those cells looks like.
 
Upvote 0
The cells are blank, not zeros.
SUM and SUMIFS ignore blanks and text by default, so you shouldn't have to worry about them.

Unless of course you are really trying to do a COUNT and not a SUM, as I mentioned in my first response. You haven't clarified that for us.

What exactly do these values being returned by your formula look like? Are they numbers, text, etc?

It might really clarify things if you post a small sample, along with your expected results. Then we will be able to see what you are really after.
 
Upvote 0
Hi Joe4

I'm afraid I can't post the file as it contains private data. However, I've just worked out the problem by your response. If the SUMIF's ignore the formula in the cell then I figured it must be an error in the formatting of the data it was totaling.

Thanks for your time and effort, really appreciate it.

SUM and SUMIFS ignore blanks and text by default, so you shouldn't have to worry about them.

Unless of course you are really trying to do a COUNT and not a SUM, as I mentioned in my first response. You haven't clarified that for us.

What exactly do these values being returned by your formula look like? Are they numbers, text, etc?

It might really clarify things if you post a small sample, along with your expected results. Then we will be able to see what you are really after.
 
Upvote 0
Excellent!

Glad you got it figured out.
 
Upvote 0

Forum statistics

Threads
1,223,888
Messages
6,175,207
Members
452,618
Latest member
Tam84

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
Back
Top