+ Reply to Thread
Results 1 to 11 of 11

Selecting cell from another sheet based on text value

  1. #1
    Registered User
    Join Date
    07-12-2019
    Location
    Serbia
    MS-Off Ver
    2013
    Posts
    4

    Selecting cell from another sheet based on text value

    I have one sheet with the range of cells with text in them, and another sheet with the range of cells with text in them and the number value next to the every cell.
    I need to choose the number value from the 2nd sheet based on the text from the 1st sheet matching some parts of text from the 2nd sheet.
    What functions should I combine in order to achieve that? Sorry if my post is confusing, and sorry for my English as well.

    Here is the simplified example so you can better understand me:
    Sheet1: A1: "excelforum 149 excel help beginner guru"; B1: (I need value from B2 cell from Sheet2 here)
    Sheet2: A1: "excelforum 132 help beginner", B1: 300; A2: "excelforum 149 help beginner", B2: 111; A3: "excelforum 149 guru", B3: 399
    Last edited by Nikolamsnc; 07-12-2019 at 06:50 AM.

  2. #2
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Selecting cell from another sheet based on text value

    INDEX / MATCH should do the trick. Something like:

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


    Adapt references to suit your workbook.
    let Source = #table({"Question","Thread", "User"},{{"Answered","Mark Solved", "Add Reputation"}}) in Source

    If I give you Power Query (Get & Transform Data) code, and you don't know what to do with it, then CLICK HERE

    Walking the tightrope between genius and eejit...

  3. #3
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,983

    Re: Selecting cell from another sheet based on text value

    Welcome to the forum.

    Will you please attach a sample Excel workbook? We are not able to work with or manipulate a picture of one and nobody wants to have to recreate your data from scratch.

    1. Make sure that your sample data are REPRESENTATIVE of your real data. The use of unrepresentative data is very frustrating and can lead to long delays in reaching a solution.

    2. Make sure that your desired results are also shown (mock up the results manually).

    3. Make sure that all confidential data is removed or replaced with dummy data first (e.g. names, addresses, E-mails, etc.).

    4. Try to avoid using merged cells as they cause lots of problems.

    Unfortunately the attachment icon doesn't work at the moment, so to attach an Excel file you have to do the following: just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.

    Please pay particular attention to point 2 (above): without an idea of your intended outcomes, it is often very difficult to offer appropriate advice.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,983

    Re: Selecting cell from another sheet based on text value

    Olly - FYI the OP mentioned partial matches, so I asked for a workbook so that we can ascertain the nature of these.

  5. #5
    Registered User
    Join Date
    07-12-2019
    Location
    Serbia
    MS-Off Ver
    2013
    Posts
    4

    Re: Selecting cell from another sheet based on text value

    Ok, here is the sample of the data

    Sometimes the text between the two sheets doesn't match at all, so it would be good if I could define additional keywords which should return particular value from sheet2, beside the text from the B column from the sheet1.
    Attached Files Attached Files
    Last edited by Nikolamsnc; 07-12-2019 at 08:02 AM.

  6. #6
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Selecting cell from another sheet based on text value

    Your data sample doesn't help me figure out what you're trying to achieve... I can't see the matches you expect.

  7. #7
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: Selecting cell from another sheet based on text value

    Administrative Note:

    Welcome to the forum.

    We would love to help you with your query; however, it has been brought to our attention the same query has been posted on one or more other forums and you have not provided the required cross-post link(s) here.

    Please see Forum Rule #3 about cross-posting and read this to understand why we (and other sites like us) consider this to be important.

    Link to x-post has been added for you this time, but please do so in the future.

    x-post: https://www.mrexcel.com/forum/excel-...ext-value.html
    Last edited by jeffreybrown; 07-12-2019 at 08:54 AM.
    HTH
    Regards, Jeff

  8. #8
    Registered User
    Join Date
    07-12-2019
    Location
    Serbia
    MS-Off Ver
    2013
    Posts
    4

    Re: Selecting cell from another sheet based on text value

    Quote Originally Posted by Olly View Post
    Your data sample doesn't help me figure out what you're trying to achieve... I can't see the matches you expect.
    I want to get value from Sheet2 G column, based on partial match between text from Sheet1 B column and Sheet2 C column. I would also add another column in Sheet2 with keywords, in order to make matching easier, because sometimes the text between Sheet1 B column and Sheet2 column is completely different.

    Destination column is Sheet1 G column.


    Value from Sheet2 G column into Sheet1 G column based on match between Sheet1 B column and Sheet2 C column + "Keyword" column (column I):


    EDIT: Uploaded edited sample, it should be easier to understand.
    Attached Files Attached Files
    Last edited by Nikolamsnc; 07-13-2019 at 02:10 AM.

  9. #9
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,983

    Re: Selecting cell from another sheet based on text value

    Nikola - did you read and understand post #7? I ask because you have now cross-posted on yet another forum, and you haven't provided cross-post links there or here.

    No help to be given until the new cross-post link has been added.
    Last edited by AliGW; 07-13-2019 at 03:31 AM.

  10. #10
    Registered User
    Join Date
    07-12-2019
    Location
    Serbia
    MS-Off Ver
    2013
    Posts
    4

    Re: Selecting cell from another sheet based on text value

    I am not allowed to post links yet, sorry.

  11. #11
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,983

    Re: Selecting cell from another sheet based on text value

    You can tell us the forums you have posted to - that is what you must do, please.

+ 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. Selecting Cells based on Row value and short new sheet based on Cell value
    By John1969 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-11-2016, 03:51 AM
  2. Replies: 1
    Last Post: 02-05-2016, 05:49 PM
  3. Exctract lines in sheet to another sheet based on text/names in cell
    By Generalist in forum Excel Programming / VBA / Macros
    Replies: 19
    Last Post: 01-12-2016, 08:32 AM
  4. Help changing macro to function, selecting based on cell being text
    By kyles123 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-16-2015, 12:12 PM
  5. Replies: 5
    Last Post: 05-29-2014, 05:09 PM
  6. Selecting a set of values from one work sheet based on a selection in another sheet
    By Abhimany in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-21-2012, 10:24 AM
  7. [SOLVED] Selecting sheets based on cell in each sheet
    By Steve in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-04-2006, 02:50 PM

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