+ Reply to Thread
Results 1 to 4 of 4

IF formula query

  1. #1
    Registered User
    Join Date
    03-10-2014
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    11

    IF formula query

    Hello there

    I need to create a list where in one column I enter a code and the next column will automatically be populated with the full description i.e.

    A1 = MIE
    B1 = Made in Egypt

    I am currently using a formula in B1 (set out below) which I have used in the past for a spreadsheet whereby B1 is a currency however when I use it for my new spreadsheet whereby both A1 & B1 are both text, I keep getting a ‘#NAME’ error. I have tried formatting both columns as ‘general’ or ‘text’ to see if this makes a difference but it hasn’t.

    The formula I have been putting in B1 is:-

    =IF(A1="MIE",Made in Egypt,(IF(A1="MIF",Made in France,(IF(A1="MIC",Made in Cyprus)))))

    Any help would be much appreciated.

    Thank you

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,852

    Re: IF formula query

    You need to put double quotes around the text strings, like this:

    =IF(A1="MIE","Made in Egypt",IF(A1="MIF","Made in France",IF(A1="MIC","Made in Cyprus")))

    I've removed some redundant brackets. If you have many more codes, then you could use VLOOKUP with a simple table of codes and meanings, and avoid multiple IFs.

    Hope this helps.

    Pete

  3. #3
    Registered User
    Join Date
    03-10-2014
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    11

    Re: IF formula query

    Thanks so much Pete. I did have quite a few more to enter so I took your advice and set up a VLOOKUP instead and it works a treat. Has speeded things up no end.

    Have a great afternoon

  4. #4
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: IF formula query

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.
    <---------If you like someone's answer, click the star to the left of one of their posts to give them a reputation point for that answer.
    Ron W

+ 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] Formula - adding an IF Query onto vlookup query
    By mra1984 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 12-06-2013, 05:31 AM
  2. Web Query - Change a word in query to form a new query
    By scottymelloty in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-25-2011, 04:13 AM
  3. If Formula Query
    By Bright Promotions in forum Excel General
    Replies: 2
    Last Post: 02-21-2011, 04:43 AM
  4. Formula query
    By Gailwdz in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-12-2005, 05:06 AM
  5. [SOLVED] formula query
    By Chiccada in forum Excel General
    Replies: 7
    Last Post: 01-07-2005, 08:06 AM

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