Nested IF Statement Formula Works, if conditions aren't met I get a #VALUE! instead of 0/Blank

c.clavin

Board Regular
Joined
Mar 22, 2011
Messages
123
Office Version
  1. 365
Platform
  1. Windows
  2. MacOS
Hi guys, I've been trying to refigure this for a while but can't seem to get it. The formula works when the cells referenced have data in them, but when its blank, I get a #VALUE! result which is affecting the rest of my calculation down the column. Can you help? Basically adding up to 3 numbers, out of 4 total statements. Thanks :)

=SUM(IF(H21="","",VLOOKUP(H21,FRUITS,2,FALSE)),IF(AND(ISNUMBER(SEARCH("Apple",H17)),ISNUMBER(SEARCH("Orange",H21))),J32,0),IF(AND(H17="",ISNUMBER(SEARCH("Orange",H21))),K32,0),IF(AND(H17="",I21="Delivery"),93,0))
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
Should I have started it with a blank/non blank if statement? Like =IF(H21="","",SUM... ?
 
Upvote 0
Hi,

Don't know anything about your data, but may be you can just wrap your formula with IFERROR, like:

=IFERROR(your formula,"")
 
Upvote 0
Hi,

Don't know anything about your data, but may be you can just wrap your formula with IFERROR, like:

=IFERROR(your formula,"")
I'm having this same issue. I attempted your solution and it did indeed get rid of the error. But the other issue I'm having is that I'm charting this data. So the chart is still plotting 0's and displaying them in the line graph.
 
Upvote 0

Forum statistics

Threads
1,214,985
Messages
6,122,607
Members
449,090
Latest member
vivek chauhan

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