+ Reply to Thread
Results 1 to 7 of 7

Vlookup to return a blank

  1. #1
    Registered User
    Join Date
    10-03-2011
    Location
    UK
    MS-Off Ver
    Excel 2003
    Posts
    85

    Vlookup to return a blank

    Hi, when I use a vlookup formula instead of displaying N/A if it cant find anything I would like it to just be a blank cell. Please can someone help.
    Last edited by gandyling; 11-08-2011 at 03:50 PM.

  2. #2
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Vlookup to return a blank

    Like this:

    =IF(ISNA(your_vlookup_formula),"",your_vlookup_formula)

    Dom
    "May the fleas of a thousand camels infest the crotch of the person who screws up your day and may their arms be too short to scratch..."

    Use code tags when posting your VBA code: [code] Your code here [/code]

    Remember, saying thanks only takes a second or two. Click the little star to give some Rep if you think an answer deserves it.

  3. #3
    Forum Contributor
    Join Date
    11-02-2011
    Location
    Rugby, England
    MS-Off Ver
    Office 365
    Posts
    846

    Re: Vlookup to return a blank

    Hi Gandyling,

    It would be easier to see your formula/worksheet, but i will have a go anyway.

    Your Vlookup - (for example)
    =vlookup(a1,data,1,false)

    To get the cell to be blank instead of N/A try this -

    =if(a1="","",vlookup(a1,data,1,false)

    The part "" in excel terms is the code for blank, so:

    =if(a1 is blank, show me blank, if not, show me my vlookup)

    Hope that helps!!
    galvinpaddy

    +=====================+

    EDIT - Domski nailed it better

  4. #4
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Vlookup to return a blank

    The cleanest way:
    use a column ( say col V) you do not need and enter the VLOOKUP and let the NA happen
    Then in your answer column enter=if(isna(V1),"",V1)

    Hide col V if needed

  5. #5
    Registered User
    Join Date
    10-03-2011
    Location
    UK
    MS-Off Ver
    Excel 2003
    Posts
    85

    Re: Vlookup to return a blank

    Thanks for your help it worked great

  6. #6
    Forum Contributor
    Join Date
    08-26-2009
    Location
    Iceland
    MS-Off Ver
    Excel 365, Windows 10
    Posts
    110

    Re: Vlookup to return a blank

    I always use iferror()

    other solutions above works too.

  7. #7
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Vlookup to return a blank

    Not in Excel 2003 you won't

    Dom

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1