Wednesday, June 8, 2011

Excel formula to check if a cell contains text


Formula

Description

=ISTEXT(A2)

Checks to see if cell A2 has text (TRUE)

=ISTEXT(A3)

Checks to see if cell A3 has text (FALSE)

=IF(A2="Davolio","OK", "Not OK")

Checks to see if A2 is Davolio (OK)

=IF(A2="Buchanan", TRUE, FALSE)

Checks to see if A2 is Buchanan (FALSE)



=IF(ISNUMBER(SEARCH("v",A2)),"OK", "Not OK")

Checks to see if A2 contain the letter v (OK)

=ISNUMBER(SEARCH("BD",A3))

Checks to see if A3 contains BD (TRUE)


No comments: