#Value Error

Rana Gray

Board Regular
Joined
Jan 26, 2023
Messages
56
Office Version
  1. 365
Platform
  1. Windows
  2. Web
Hey everyone! I need some help tweaking my formula to get rid of the #VALUE error it's generating.

Formula Goal: if range 1 (date format) is a Saturday, then sum the relevant cell in range 2 (number format) >> count how many of something is being done on Saturdays specifically out of all the days logged.

Formula: =SUMPRODUCT(--(WEEKDAY($B$4:$B$63)=7)*--$W$4:$W$63)

When I step into the formula I can see the problem are the blank cells in the range - I've used this formula before and haven't had an issue with this, but now I can't seem to find a workaround.

Any suggestions? (PS. I confirmed my observation by reducing the ranges to just the cells with data and it work fined)
 

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"
Are you sure that these cells are blank? Or mey be there are some non-printing characters? Or formulas, which return empty strings, like if(condition,value,"") etc.?

May be you could give a try to:

Excel Formula:
=SUMPRODUCT(IF(ISNUMBER($B$4:$B$63)*ISNUMBER($W$4:$W$63),(WEEKDAY($B$4:$B$63)=7)*$W$4:$W$63,0))
 
Upvote 0
Solution
Are you sure that these cells are blank? Or mey be there are some non-printing characters? Or formulas, which return empty strings, like if(condition,value,"") etc.?

May be you could give a try to:

Excel Formula:
=SUMPRODUCT(IF(ISNUMBER($B$4:$B$63)*ISNUMBER($W$4:$W$63),(WEEKDAY($B$4:$B$63)=7)*$W$4:$W$63,0))
Thank you this solved the problem, and to answer your question I made sure to clear cell contents and delete any phantom entries :) this did the trick! I appreciate you!
 
Upvote 0
Try
Excel Formula:
=SUM(IFERROR((WEEKDAY($B$4:$B$63,1)=7)*$W$4:$W$63,0))
Thank you this did work with one hiccup if I had additional entries in range W it would sum all of it vs just what met my condition in range B :) I appreciate the help!
 
Upvote 0
Glad we could help!
And thanks for feedback!
 
Upvote 0

Forum statistics

Threads
1,225,481
Messages
6,185,236
Members
453,283
Latest member
Shortm88

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