user3324466
user3324466

Reputation: 1

Syntax of double brackets double quotes in excel

I don't understand the syntax of the following logical test in an if statement in excel:

if(cell designator <>"", value if true, value if false.

Could someone explain what the brackets and quotes are testing for?

Upvotes: 0

Views: 178

Answers (4)

Boshi
Boshi

Reputation: 230

<> means Not equal to

"" means empty or blank

The whole expression is saying "If value of given cell is blank/empty then result1 (true value) otherwise result2 (false value)"

Upvotes: 0

WGS
WGS

Reputation: 14179

<>"" Excel's way of checking if the string contains a valid value/string. It's almost the same as =IF(LEN(A1)=0....

However, this will not check for you if a cell is entirely blank. A perfect example would be entering just ' in A1. Input =A1<>"" in B1 and it will return TRUE.

Now try =ISBLANK(A1), and it will return FALSE. Hence, why I used the term valid.

Upvotes: 2

NickC
NickC

Reputation: 385

The <> operator means NOT EQUAL. Therefore it is checking if the cell's value is not an empty string.

Upvotes: 0

gtwebb
gtwebb

Reputation: 3011

The double quotes indicates a blank cell. So it could be read as

if (cell designator is blank, true, false)

Upvotes: 0

Related Questions