help needed with vlookup?

wylie88

New Member
Joined
Jan 25, 2005
Messages
3
Im useing this formula in my system and when there is nothing in B5 it just comes up as NA. is there any way to stop this from happening?


=VLOOKUP(B5,'Product database'!C2:E24,3,0)

thanks
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
=if(iserror(VLOOKUP(B5,'Product database'!C2:E24,3,0)),0,VLOOKUP(B5,'Product database'!C2:E24,3,0))

If you change the 0 for "", it will leave the cell blank.
Or you can put in text to identify errors "Missing"
 
Upvote 0
try this:

=if(isna(VLOOKUP(B5,'Product database'!C2:E24,3,0)),"",(VLOOKUP(B5,'Product database'!C2:E24,3,0)))

Regards
Asim
 
Upvote 0
wylie88 said:
Im useing this formula in my system and when there is nothing in B5 it just comes up as NA. is there any way to stop this from happening?


=VLOOKUP(B5,'Product database'!C2:E24,3,0)

thanks

If C2:E24 is sorted on C2:C24 in ascending order...

=IF(B5 < INDEX($C$2:$C$24,1,1),"",LOOKUP(B5,'Product database'!$C$2:$C$24)=B5,LOOKUP(B5,'Product database'!$C$2:$E$24))

If C2:E24 is not sorted on C2:C24...

D5:

=IF(B5<>"",VLOOKUP(B5,'Product database'!$C$2:$E$24,3,0),"")

C5:

=IF(ISNA(D5),"",D5)
 
Upvote 0

Forum statistics

Threads
1,214,591
Messages
6,120,428
Members
448,961
Latest member
nzskater

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