+ Reply to Thread
Results 1 to 3 of 3

Extracting text value from string

  1. #1
    Registered User
    Join Date
    03-31-2012
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    84

    Extracting text value from string

    I'm trying to extract the text that sits between the last underscore ('_') and the plus sign ('+'). Example string below

    #TTD_textabc-xyv-cdef_DISPLAY-OCT15-UK_120x600+211458

    From this i'd like to extract 120x600. The string text length can be any number of characters... i just need to extract whatever is between the last underscore and '+'

    I've tried this =TRIM(MID(D2,FIND("_",D2)+1,FIND("+",D2)-FIND("_",D2)-1)) which gets me part way there, but I can't seem to get the 'REPT' function working in tandem with the FIND function. (No text to columns suggestions pleas )

    Help appreciated.

  2. #2
    Forum Guru samba_ravi's Avatar
    Join Date
    07-26-2011
    Location
    Hyderabad, India
    MS-Off Ver
    Excel 2021
    Posts
    8,914

    Re: Extracting text value from string

    =TRIM(LEFT(SUBSTITUTE(RIGHT(SUBSTITUTE(D2,"_",REPT(" ",LEN(D2))),LEN(D2)),"+",REPT(" ",LEN(D2))),LEN(D2)))
    Try this one
    Samba

    Say thanks to those who have helped you by clicking Add Reputation star.

  3. #3
    Registered User
    Join Date
    03-31-2012
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    84

    Re: Extracting text value from string

    You beauty. Thanks Siva!

+ 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. Extracting text from a string
    By simonelvin in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 10-10-2014, 06:58 AM
  2. Extracting text from a string
    By AlexDeLara in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 02-26-2014, 04:41 AM
  3. Extracting numbers and text from inconsistent text/number formatted string
    By Brandivil in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-25-2013, 01:46 PM
  4. [SOLVED] Extracting Text from a string of Text & Digits of variable length
    By hastex in forum Excel General
    Replies: 6
    Last Post: 06-06-2012, 09:11 AM
  5. Extracting text from a string
    By excelhelp18 in forum Excel General
    Replies: 1
    Last Post: 04-05-2012, 03:08 AM
  6. Extracting the last name of a string of text
    By simjambra in forum Excel General
    Replies: 7
    Last Post: 05-15-2009, 11:04 AM
  7. Extracting just the last name in a text string
    By braydon16 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-06-2008, 08:19 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