+ Reply to Thread
Results 1 to 8 of 8

VLOOKUP/formula produces #N/A

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    11-09-2007
    Location
    USA
    MS-Off Ver
    2003
    Posts
    141

    VLOOKUP/formula produces #N/A

    I am using this formula:
    =IF(O6>0,"",(VLOOKUP(A6,Material!A2:G43,7,FALSE)))/2000*O6

    and it produces #N/A in the cell that contains this formula. If cell A6 has an item selected in it I made from data validation-list then the output is $0.00.

    How can eliminate anything from showing if the list is blank in cell A6?Thanks for helping!!
    Last edited by ge0rge; 03-26-2009 at 10:17 AM.

  2. #2
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    Re: VLOOKUP/formula produces #N/A i

    Try this:
    =IF(OR(O6>0,A6=""),"",VLOOKUP(A6,Material!A2:G43,7,FALSE)/2000*O6)

    Does that help?
    Ron
    Former Microsoft MVP - Excel (2006 - 2015)
    Click here to see the Forum Rules

  3. #3
    Forum Contributor
    Join Date
    11-09-2007
    Location
    USA
    MS-Off Ver
    2003
    Posts
    141

    Re: VLOOKUP/formula produces #N/A i

    It semi-works. It does get rid of the #N/A. When I select a material in my list it then show $0.00 which is good. As soon as I enter a number into O6 the $0.00 found in AD6(cell containing your formula) goes away and the computation is not performed.

  4. #4
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    Re: VLOOKUP/formula produces #N/A

    Still not really sure what you're looking to do.
    Per you original formula, if O6>0...don't perform a calculation.

    In this formula:

    =IF(O6>0,A6=""),"",VLOOKUP(A6,Material!A2:G43,7,FALSE)/2000*O6)
    If O6>0 or A6 does not have a value selected,
    then no calculation is performed.

    Can you described the rules?

  5. #5
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: VLOOKUP/formula produces #N/A

    Is there for sure a match for A6 in Material! sheet?

    Try:

    =IF(ISNUMBER(MATCH(A6,Material!A2:G43,0)),IF(OR(O6>0,A6=""),"",VLOOKUP(A6,Material!A2:G43,7,FALSE)/2000*O6),"")
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  6. #6
    Forum Contributor
    Join Date
    11-09-2007
    Location
    USA
    MS-Off Ver
    2003
    Posts
    141

    Re: VLOOKUP/formula produces #N/A

    that formula produces a blank cell. Here is a sample.
    Attached Files Attached Files

  7. #7
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: VLOOKUP/formula produces #N/A

    Try:

    =IF(AND(O3>0,A3<>""),VLOOKUP(A3,Materials!$A$2:$G$43,7,FALSE)/2000*O3,"")

    in AD3, copied down

  8. #8
    Forum Contributor
    Join Date
    11-09-2007
    Location
    USA
    MS-Off Ver
    2003
    Posts
    141

    Re: VLOOKUP/formula produces #N/A

    That worked. Thanks to all for the help!!

+ 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