Calc: Checking whether a range of cells are blank via a formula

I’m trying to create a formula that checks whether a range of cells above it are blank.

Ie, =IF(AND(E21>$C$16, $H$21:H22="");“Here!”;"")

gives a #value error. Using F9 I found the error is $H$21:H22="". It works for a single cell, so I assume you can’t check a range this way. So how do I do it?

Background: Simple physics spreadsheet. Each row increments a calculation, I want a flag to draw my attention to the spot where the calculation swings from negative to positive. Using =IF(E21>$C$16;“Here!”;"") works, but then it has “Here!” on every positive row.
ie,
.
Here!
Here!
Here!
Here!

I would prefer to only have it appear once, on the first row it flips:
.
Here!
.
.
.

If you are interested in attracting attention only, then why not take advantage of the conditional formatting? Small demo - Flags to draw attention.ods

Try this array formula:

=IF(($C$5<E10:E11)*ISBLANK($H$10:H11);“Here!”;"")

Introduce with Ctrl+Shift+Enter, the AND() OR() don’t work in array formulas.

Doesn’t work with the range/array in isblank. =IF(ISBLANK(H10);“True”;“False”) shows True. =IF(ISBlank(H11);“True”;“False”) also shows true. But =IF(ISBLANK(H10:H11);“True”;“False”) shows False.

IsBlank is not uspposed to work with a cell range. See OASIS Open Document Format for Office Applications (OpenDocument) Version 1.2 - Part 2: Recalculated Formula (OpenFormula) Format

I didn’t understand well what Paul451 want.

I hope the next array formula works as wanted.

=IF(($C$16E21:E41)*($C$16=E20:E40);“here!”;"") (Ctrl+Shift+Enter)

Only shows here!, when the previous cell does not satisfy the condition.

Mariosv, you can’t test a range against a conditional (like >= ). You can’t use a range with ISBLANK(). So H21="" returns TRUE. H20="" returns TRUE. Even (H20="")*(H21="") returns TRUE. But H20:H21="" returns #VALUE error. How do you test a range/array against another value?

I can’t be the first person in spreadsheet history to want to check all the cells in an array/range against a single value? There must be some way to do it.

Hi @Paul451,

Still looking for an answer here? Have you found an answer already?

Why don’t you try countif(,"")=counta()?