+ Reply to Thread
Results 1 to 4 of 4

Number and Text Link

  1. #1
    Registered User
    Join Date
    03-27-2013
    Location
    Boston, MA
    MS-Off Ver
    Excel 2010
    Posts
    50

    Number and Text Link

    Hello,

    I am trying to create a simple link between numbers and text in excel. I have 3 states: 1 = worse case 2 = base case 3= best Case.

    I want to create a formula that allows me to link these. For example, if I type in "Worse Case" in a cell, the number 1 should pop up on another cell. If I type in "Base Case", then the number 2 would pop up in another cell.

    How can I do this?

    Thanks for the help!

  2. #2
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Number and Text Link

    Several ways
    VLOOKUP
    Put the values in a separate table, Let's say G1:H3 with text in G and number in H
    Let's say you put "Worst case" in A2, in B2
    =VLOOKUP(A2, $G$1:$H$3,2, FALSE)

    with LOOKUP
    =LOOKUP(A2, {"base case", "best case", "worst case"}, {2, 3, 1})
    Edit: Note: The "cases" need to be in alphabetical order for LOOKUP
    Last edited by ChemistB; 03-27-2013 at 01:21 PM.
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  3. #3
    Valued Forum Contributor Melvinrobb's Avatar
    Join Date
    06-19-2012
    Location
    Manitoba, Canada
    MS-Off Ver
    Excel 2013
    Posts
    1,128

    Re: Number and Text Link

    An if statement would accomplish this:

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Please click the * icon below if I have helped.

  4. #4
    Valued Forum Contributor Melvinrobb's Avatar
    Join Date
    06-19-2012
    Location
    Manitoba, Canada
    MS-Off Ver
    Excel 2013
    Posts
    1,128

    Re: Number and Text Link

    An if statement would accomplish this:

    Formula: copy to clipboard
    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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