+ Reply to Thread
Results 1 to 4 of 4

Find a value and return a corresponding number

  1. #1
    Registered User
    Join Date
    05-09-2006
    Posts
    9

    Find a value and return a corresponding number

    Hi!

    This is my problem:
    I am working on a list A1:B1000.
    Colum A contain nr values and colum B contain string values.
    I don't want duplicate values in the B colum of the list so I have formatted the list with Validation to notice me when I type in a string value that already excist.

    But I wonder if it is possible not only to give me this notice but to return the corresponding value in colum A?

    Example: In the end of the list at cell B1034 I type the word Norway.
    This word already excist in cell B55, so i am noticed and the value in cell A55 is returned to me.

    regards, Irene

  2. #2
    Gary''s Student
    Guest

    RE: Find a value and return a corresponding number

    First turn off the validation to allow Norway to be entered a second time.

    Then in C1 enter:

    =IF(COUNTIF(B:B,"="&B1)=1,"",INDIRECT("A"&MATCH(B1,B:B,0)))

    and copy down. The formula will be blank for all entries in column B
    appearing only once. Otherwise it will display the equivalent value from
    column A
    --
    Gary''s Student


    "Irene" wrote:

    >
    > Hi!
    >
    > This is my problem:
    > I am working on a list A1:B1000.
    > Colum A contain nr values and colum B contain string values.
    > I don't want duplicate values in the B colum of the list so I have
    > formatted the list with Validation to notice me when I type in a string
    > value that already excist.
    >
    > But I wonder if it is possible not only to give me this notice but to
    > return the corresponding value in colum A?
    >
    > Example: In the end of the list at cell B1034 I type the word Norway.
    > This word already excist in cell B55, so i am noticed and the value in
    > cell A55 is returned to me.
    >
    > regards, Irene
    >
    >
    > --
    > Irene
    > ------------------------------------------------------------------------
    > Irene's Profile: http://www.excelforum.com/member.php...o&userid=34269
    > View this thread: http://www.excelforum.com/showthread...hreadid=541157
    >
    >


  3. #3
    Registered User
    Join Date
    05-09-2006
    Posts
    9
    Thanx, you are awsame

  4. #4
    Gary''s Student
    Guest

    Re: Find a value and return a corresponding number

    You are very welcome!
    --
    Gary''s Student


    "Irene" wrote:

    >
    > Thanx, you are awsame
    >
    >
    > --
    > Irene
    > ------------------------------------------------------------------------
    > Irene's Profile: http://www.excelforum.com/member.php...o&userid=34269
    > View this thread: http://www.excelforum.com/showthread...hreadid=541157
    >
    >


+ 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