trouble with #REF! error

Mark Arthur

New Member
Joined
Jun 21, 2019
Messages
9
This is my formula but if any cell in range c5-c41 is blank it returns a ref error

=IF(SUMPRODUCT(SUMIF(INDIRECT("'"&Settings!$C$5:$C$41&"'!H13:H55"),B3,INDIRECT("'"&Settings!$C$5:$C$41&"'!Y13:Y55")))=0,"",SUMPRODUCT(SUMIF(INDIRECT("'"&Settings!$C$5:$C$41&"'!H13:H55"),B3,INDIRECT("'"&Settings!$C$5:$C$41&"'!Y13:Y55"))))
 
For someone who is self confessed as being not too proficient at excel I really think you should be removing your blank cells rather than using the iferror. The iferror will mask other potential problems with your data other than the indirect pointing to a sheet with no name. It's up to you but has pitfalls.
 
Upvote 0

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)
If I could have it skip blanks then that would be ok. But like I said the blank spaces are a list that can be filled out on a settings page. The list of races could be as short as 5 or as long as 37. How do I have a dynamic list that can grow in other formulas as or if it’s filled in. I thought about using a table but once you delete the contents it remains the same size, so back to blanks the next time it’s filled in.
 
Upvote 0

Forum statistics

Threads
1,215,332
Messages
6,124,314
Members
449,153
Latest member
JazzSingerNL

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