ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Why =if(A2:A4="",1,0) will output #VALUE ? (https://www.excelbanter.com/excel-worksheet-functions/140001-why-%3Dif-a2-a4%3D-1-0-will-output-value.html)

Pearie

Why =if(A2:A4="",1,0) will output #VALUE ?
 
How to check if there is empty cell in a range by using IF Statement ?

I used to use IF Statement to detect empty cell within a range as EXAMPLE
listed below. It works in the past but suddenly fails and output "#VALUE".
Why ?

BEFORE :
Statement : =IF(A2:A4="",1,0)
When A3 = "Null"
Output : "1"

PRESENT :
Output : "#VALUE"



BK Lim

Why =if(A2:A4="",1,0) will output #VALUE ?
 
It is an array entry. You need to press shift-ctrl-enter in order to get it
works.

"Pearie" wrote:

How to check if there is empty cell in a range by using IF Statement ?

I used to use IF Statement to detect empty cell within a range as EXAMPLE
listed below. It works in the past but suddenly fails and output "#VALUE".
Why ?

BEFORE :
Statement : =IF(A2:A4="",1,0)
When A3 = "Null"
Output : "1"

PRESENT :
Output : "#VALUE"



JE McGimpsey

Why =if(A2:A4="",1,0) will output #VALUE ?
 
One way:

=--(COUNTIF(A2:A4,"")0)

alternatively (array-entered: CTRL-SHIFT-ENTER or CMD-RETURN):

=OR(A2:A4="")


Don't know why your formula worked in the past...


In article ,
Pearie wrote:

How to check if there is empty cell in a range by using IF Statement ?

I used to use IF Statement to detect empty cell within a range as EXAMPLE
listed below. It works in the past but suddenly fails and output "#VALUE".
Why ?

BEFORE :
Statement : =IF(A2:A4="",1,0)
When A3 = "Null"
Output : "1"

PRESENT :
Output : "#VALUE"



All times are GMT +1. The time now is 02:23 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com