# IF statement, Simple Question

#### jrwrita

##### Board Regular
Hi All,

Say I have a Vlookup, and if it returns a value I want it to say TRUE or even my own term such as 'matched', and if the vlookup returns an #N/A I want a False or my own custom term. Is there anyway to do this?

Thanks.

### Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
What is the value the lookup returns?

As in, is it a number or text?

Last edited:
What is the value the lookup returns?

As in, is it a number or text?

Lookup returning numbers

Then try

=IF(ISNUMBER(VLOOKUP()),"True","False")

Just my way.....

SHEET 1

 A B C 1 Peter 22.99 2 John 10 3 Craig 20 4 mark 19.99 5 Steven 13.55 6 Ralph 23.44 7 Roger 22.22

<colgroup><col width="64" span="3" style="width:48pt"> </colgroup><tbody>
</tbody>

First way...

=IF(VLOOKUP(A1,Sheet1!B1:C7,2,FALSE)>15.99,"TRUE","FALSE")

Second Way

=IFERROR(IF(MATCH(A9,Sheet1!B:B,0),"TRUE"),"FALSE")

Just my way.....

SHEET 1

 A B C 1 Peter 22.99 2 John 10 3 Craig 20 4 mark 19.99 5 Steven 13.55 6 Ralph 23.44 7 Roger 22.22

<tbody>
</tbody>

First way...

=IF(VLOOKUP(A1,Sheet1!B1:C7,2,FALSE)>15.99,"TRUE","FALSE")

Second Way

=IFERROR(IF(MATCH(A9,Sheet1!B:B,0),"TRUE"),"FALSE")

The 1st one won't work if it doesn't find the lookup value. It will still return #N/A.

Replies
7
Views
476
Replies
7
Views
2K
Replies
1
Views
189
Replies
2
Views
187
Replies
9
Views
356

1,196,119
Messages
6,013,570
Members
441,774
Latest member
esandoval

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back