Showing an empty cell instead of "#N/A" ?

LucidCheetah

New Member
Joined
Dec 11, 2017
Messages
15
I am using vlookup to populate cells in one column of my sheet, but when I have no value in the C column to draw from, the B column displays "#N/A". How can I modify this line to show an empty cell until I have input my value into the C column?

Code:
=VLOOKUP(C2,'Sheet2'!$A$1:$B$2662,2,0)
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
If you have Excel 2007 or newer:

=IFERROR(VLOOKUP(C2,'Sheet2'!$A$1:$B$2662,2,0),"")

Eric is correct.

On the offchance you are stuck with an older version of Excel, you could use something like this:

=IF(ISERROR(VLOOKUP(C2,'Sheet2'!$A$1:$B$2662,2,0)),"",VLOOKUP(C2,'Sheet2'!$A$1:$B$2662,2,0))
 
Upvote 0
If you have Excel 2007 or newer:

=IFERROR(VLOOKUP(C2,'Sheet2'!$A$1:$B$2662,2,0),"")

Thanks! I figured it was something along thos elines from my Googling, but I kept putting an extra "=" in front of vlookup in the brackets and couldn't figure out what i was doing wrong! Thanks again.
 
Upvote 0
If you have Excel 2013 or newer you can switch out IFERROR for IFNA. It will only trap #N/A errors, so things such as #REF will still flag.
 
Upvote 0

Forum statistics

Threads
1,223,060
Messages
6,169,860
Members
452,286
Latest member
noclue2000

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