jeudi 11 février 2021

Why does an If statement behave differently for range compared to just a cell in excel

Say I want to output a column that ignores "-" and "" cells and returns anything else.

=IF(OR(A2="",A2="-"),"",A2) and dragging down works but why cant this be applied to a range of values?

For example:

=IF(OR(A2:A11="",A2:A11="-"),"",A2:A11) just returns blank cells.

Similarly: =IF(OR((A2:A11="")*(A2:A11=""),(A2:A11="-")*(A2:A11="-")),"",A2:A11) causes the same result.

Could anyone explain why this happens.

Thanks

Aucun commentaire:

Enregistrer un commentaire