Consulting

Results 1 to 5 of 5

Thread: Solved: vlookup and the value #N/A

  1. #1
    VBAX Newbie
    Joined
    Nov 2005
    Location
    Brussels
    Posts
    4
    Location

    Solved: [SOLVED] vlookup and the value #N/A

    Good morning everyboody!

    I use the formulas "vlookup" or "hlookup" with the parameter "false".
    When there is the value #N/A, I would like that it is replaced by other string of character.
    For to make it, I have used the conditional "if" with the following way:
    "if(vlookup(*,*,*,false)="#N/A","...","...")".
    It dosen't work. It still displays "#N/A".
    Does anyone know how to make?

  2. #2
    Knowledge Base Approver
    The King of Overkill!
    VBAX Master
    Joined
    Jul 2004
    Location
    Rochester, NY
    Posts
    1,727
    Location
    Hi brunocaccio,

    Welcome to vbax!

    You're on the right track, just a little different syntax.
    =IF(ISERROR(vlookup(*,*,*,false),"...",vlookup(*,*,*,false))

    Matt

  3. #3
    VBAX Newbie
    Joined
    Nov 2005
    Location
    Brussels
    Posts
    4
    Location
    Thank you very much!

  4. #4
    Knowledge Base Approver
    The King of Overkill! VBAX Master
    Joined
    Jul 2004
    Location
    Rochester, NY
    Posts
    1,727
    Location
    Glad to help!

    And for reference, you can mark it the whole title solved by going to Thread Tools at the top of the thread, and choosing "Mark Thread Solved". I'll take care of it on this one (I saw the [SOLVED] above)

    Let me know if you need anything else! I believe there is also an ISNA function, which could let you separate the error if there are more (and you want the specificity). But ISERROR works for me every time
    Matt

  5. #5
    Mac Moderator VBAX Expert shades's Avatar
    Joined
    May 2004
    Location
    Kansas City, USA
    Posts
    638
    Location
    Just as a note:

    ISERROR - Returns TRUE if the cell contains any error value (#N/A, #VALUE!, #REF!, # DIV/0!, #NUM!, #NAME?, #NULL!)

    ISERR - Returns TRUE if the cell contains any error value except #N/A

    ISNA - Returns TRUE if teh cell contains the #N/A error value

    Software: LibreOffice 3.3 on Mac OS X 10.6.5
    (retired Excel 2003 user, 3.28.2008 )
    Humanware: Older than dirt
    --------------------
    old, slow, and confused
    but at least I'm inconsistent!

    Rich

Posting Permissions

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