counting blanks in a non-consecutive range

J

jenniebentham

I need to be able to count the number of blank cells in a range, but my range
is made up of non-consecutive cells, ie B2, D2, F2, H2.

I have tried naming the range 'actual' and then using =COUNTBLANK(actual)
but I get #VALUE!

I have also tried =COUNTBLANK(B2,D2,F2,H2) but it will not accept the formula.

Any suggestions?
 
M

Mike H

Maybe:-

=SUM(IF(ISBLANK(B2),1,0)+IF(ISBLANK(D2),1,0)+IF(ISBLANK(F2),1,0)+IF(ISBLANK(H2),1,0))

Enter with Ctrl+shift+enter

Mike
 
J

jenniebentham

Lovely - thank you!

Mike H said:
Maybe:-

=SUM(IF(ISBLANK(B2),1,0)+IF(ISBLANK(D2),1,0)+IF(ISBLANK(F2),1,0)+IF(ISBLANK(H2),1,0))

Enter with Ctrl+shift+enter

Mike
 
R

Ron Coderre

Try this:

=SUMPRODUCT((COLUMN(B2:H2)={2;4;6;8})*ISBLANK(B2:H2))

Does that help?
--------------------------

Regards,

Ron (XL2003, Win XP)
Microsoft MVP (Excel)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top