Vlookup returning #NA

danwaddy

New Member
Joined
Mar 4, 2014
Messages
7
Hi all, i have a formula =VLOOKUP("x",E10:F13,2) which is returning #NA and i want it to return 0 (Zero)

How can i achieve this?

hope you can help.
 

Excel Facts

Wildcard in VLOOKUP
Use =VLOOKUP("Apple*" to find apple, Apple, or applesauce
You mean the right answer is Zero or if it returns an error (#NA) then you want it to be a zero?

Just to confirm if the correct answer should be Zero, does column E contain an x in rows 10 - 13?
then does Column F contain a Zero on the same row as the x?

 
Upvote 0
Hi

if it returns an error (#NA) then i want it to be a zero.

column E doesnt contain an x in rows 10 - 13 at the moment but will when populated. Column F defines the value to be shown in the cell with the formula

Thanks for the response
 
Upvote 0
Are you trying to do an exact match and is your search range going to be the same in each of the formuals you use?

if you want an exact match, you current formula becomes the below (added a ,0 at the end)
=VLOOKUP("x",E10:F13,2, 0)

if you want the range of cells to be the same if you copy this formula down it becomes the below (added $ signs to stop the range changing as you copy the formula

=VLOOKUP("x",$E$10:$F$13,2,0)

Now to your errors, Depending on your version of Excel try the below

=iferror(VLOOKUP("x",$E$10:$F$13,2, 0),0)



or

​=IF(ISERROR(VLOOKUP("x",$E$10:$F$13,2,0)),0,VLOOKUP("x",$E$10:$F$13,2,0))
 
Upvote 0
This works perfect =iferror(VLOOKUP("x",$E$10:$F$13,2, 0),0)

thanks for this, much appreciated.
 
Upvote 0

Forum statistics

Threads
1,215,064
Messages
6,122,936
Members
449,094
Latest member
teemeren

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.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

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

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

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
Back
Top