+ Reply to Thread
Results 1 to 7 of 7

getting #NAME? error but syntax looks OK to me - VLOOKUP & MATCH Issue

  1. #1
    Registered User
    Join Date
    09-30-2018
    Location
    Lancashire, England
    MS-Off Ver
    365
    Posts
    17

    Question getting #NAME? error but syntax looks OK to me - VLOOKUP & MATCH Issue

    I have several sheets named as:
    Sheet 1 – Choices
    Sheet 2 – Extras
    Sheet 3 – UpgradePriceToPurchaser
    Sheet 4 – AllHouseTypes_LkUp

    On the Choices sheet, I have a cell ($H$10) with the following formula
    =IFNA(VLOOKUP($F$10,AllHouseTypes_LkUp!$A$3:$B$64,2,FALSE),"")
    There are currently only three possible outcomes for this cell: blank, Detached or MewsSemi

    On the Extras sheet, I have a cell with the following formula
    =IF($N56<>"Extra", 0, IF(Choices!$H$10 = “MewsSemi”, 600, IFNA(VLOOKUP(H56,UpgradePriceToPurchaser!A$87:AZ$103, MATCH(Choices!$F$10,UpgradePriceToPurchaser!$A$1:$AZ$1,1),0),0)))

    The IFNA(VL...) section, in my question, I believe is irrelevant since the result I am trying to test is where Choices!$H$10 = “MewsSemi”, but the result I get is #NAME? plus, the IFNA(VL...) bit works when not as part of this formula

    The images show the part result when I evaluate the formula:

    So, QUESTION: Why the hell won’t it work ☹? The result should be 600

    thanks in advance

    Screenshot (155).png

    Screenshot (156).png

  2. #2
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,070

    Re: getting #NAME? error but syntax looks OK to me - VLOOKUP & MATCH Issue

    You appear to have the wrong type of quotes here
    IF(Choices!$H$10 = “MewsSemi”, 600,

    They should be " not “ and ”

  3. #3
    Registered User
    Join Date
    09-30-2018
    Location
    Lancashire, England
    MS-Off Ver
    365
    Posts
    17

    Re: getting #NAME? error but syntax looks OK to me - VLOOKUP & MATCH Issue

    Thanks for the response.

    not sure how to change the quote type since it is evaluated...

    Attachment 643511

  4. #4
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,070

    Re: getting #NAME? error but syntax looks OK to me - VLOOKUP & MATCH Issue

    It's in the formula you posted. Compare the quotes around the word Extra at the start of the formula & those around MewsSemi

  5. #5
    Registered User
    Join Date
    09-30-2018
    Location
    Lancashire, England
    MS-Off Ver
    365
    Posts
    17

    Thumbs up Re: getting #NAME? error but syntax looks OK to me - VLOOKUP & MATCH Issue

    OMG!

    i would never have spotted that in a million years! Brilliant, thanks...it worked.

    I had messed about with the formula in Word first, and then copied & pasted it in to Excel. Clearly Word messed up the quote types.

    thanks again

  6. #6
    Forum Expert
    Join Date
    10-10-2016
    Location
    Sheffield
    MS-Off Ver
    365 and rarely 2016
    Posts
    3,210

    Re: getting #NAME? error but syntax looks OK to me - VLOOKUP & MATCH Issue

    Notepad is a much safer option than word!

  7. #7
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,070

    Re: getting #NAME? error but syntax looks OK to me - VLOOKUP & MATCH Issue

    Glad to help & thanks for the feedback

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Vlookup to external workbook giving runtime or syntax error.
    By damngroundhog in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 07-24-2019, 09:55 PM
  2. Index and Match syntax error
    By kocumna in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 06-14-2018, 03:06 PM
  3. VBA Match Function Syntax Issue
    By ajmplanner in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-27-2016, 12:51 PM
  4. Syntax Error in vlookup(hlookup Formula
    By ExcelFinWizzard in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-15-2014, 07:05 PM
  5. Match with Muliple Criteria VBA Syntax Issue
    By beat in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 04-23-2013, 09:13 AM
  6. Issue with IF(ISERROR(VLOOKUP syntax
    By jh9 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-20-2011, 12:45 PM
  7. Syntax error found in vba vlookup
    By Junior728 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-21-2005, 10:05 PM

Tags for this Thread

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