If you only want to return an empty field when B2 is empty, you can use the additional IF function for this scenario, i.e.
=IF(B2="","",VLOOKUP(B2,Index!A1:B12,2,FALSE))
or return an empty string with any error from VLOOKUP (for example, if B2 is full, but VLOOKUP is not found), you can use the IFERROR function if you have Excel 2007 or later, i.e.
=IFERROR(VLOOKUP(B2,Index!A1:B12,2,FALSE),"")
in earlier versions you need to repeat VLOOKUP, for example
=IF(ISNA(VLOOKUP(B2,Index!A1:B12,2,FALSE)),"",VLOOKUP(B2,Index!A1:B12,2,FALSE))
barry houdini Jan 07 '13 at 20:14 2013-01-07 20:14
source share