vlookup to include text

L

Louise

Hello

I wish to create a VLookUp which will return text when a match is found
rather than data from the lookup table. Can this be done?

Thank you.
Louise
 
T

Toppers

This will return the text "My text" if a match is found (and blank if no match)

=IF(ISNA(VLOOKUP(C1,$A$1:$B$5,2,FALSE)),"","My text")

..... is this what is required?
 
K

kassie

You can return text whether a match is found or not. For example
=IF(ISNA(VLOOKUP(D1,$A$1:$C$15,2,FALSE)),"No Match", "Match"), will return
the words No Match, if no match is found, and Match if a match is found.
 
L

Louise

Excellent, thank you.
Louise

Toppers said:
This will return the text "My text" if a match is found (and blank if no match)

=IF(ISNA(VLOOKUP(C1,$A$1:$B$5,2,FALSE)),"","My text")

.... is this what is required?
 
L

Louise

Worked great, thank you.
Louise

Toppers said:
This will return the text "My text" if a match is found (and blank if no match)

=IF(ISNA(VLOOKUP(C1,$A$1:$B$5,2,FALSE)),"","My text")

.... is this what is required?
 
L

Louise

Worked great, thank you.

kassie said:
You can return text whether a match is found or not. For example
=IF(ISNA(VLOOKUP(D1,$A$1:$C$15,2,FALSE)),"No Match", "Match"), will return
the words No Match, if no match is found, and Match if a match is found.
 
T

Toppers

Take a look at the "Information" functions:

ISNA Value refers to the #N/A (value not available) error value.

Simply, the value (match) cannot be found.
 
Top