+ Reply to Thread
Results 1 to 4 of 4

Extract data from text string

  1. #1
    Forum Contributor
    Join Date
    04-21-2009
    Location
    England
    MS-Off Ver
    Excel 2016
    Posts
    710

    Extract data from text string

    Hello there, I have attached my example workbook. In cell A1 I have a text string, with a comma separating each entity.

    I would like to extract and stack each entrant as shown in the example. So the name will appear in B and the price in C.

    Could someone help with the formula needed to extract and order in this way from the text string in A1
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: Extract data from text string

    This is not that easy using formulas. I would either approach it with VBA or text to columns.

    With text to columns:
    -select A1 and use the text to columns tool with ", " as a delimiter
    -copy the resulting row and pastespecial using transpose to change from rows to columns
    -select the resulting column and use " " as a delimiter

    for a macro, either record the above process as a macro. Or use the VBA split function to manipulate the data into the correct array first before assigning to your range.

  3. #3
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Extract data from text string

    Please see attached file with formulas.
    Attached Files Attached Files
    If you like my answer please click on * Add Reputation
    Don't forget to mark threads as "Solved" if your problem has been resolved

    "Nothing is so firmly believed as what we least know."
    --Michel de Montaigne

  4. #4
    Valued Forum Contributor TheCman81's Avatar
    Join Date
    11-06-2012
    Location
    Edinburgh, UK
    MS-Off Ver
    Excel 2003, 2007, 2010, 2013
    Posts
    346

    Re: Extract data from text string

    If you don't mind having the odds first then this will work for you

    Could prob make it shorter

    Example v2.xlsx
    Excel Guru in the making

    <----------If the question has been answered to your satisfication please click the Add Repuation star to the left

  5. #5
    Forum Contributor
    Join Date
    04-21-2009
    Location
    England
    MS-Off Ver
    Excel 2016
    Posts
    710

    Re: Extract data from text string

    Thanks all for your suggestions and help. I can work with it having the odds first

+ 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] Extract data from text string
    By cmb80 in forum Excel General
    Replies: 14
    Last Post: 07-16-2014, 11:29 AM
  2. [SOLVED] Extract text from a given point in a text string, when data points do not share the given
    By reedersketer in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 07-09-2014, 03:57 PM
  3. Extract data from text string to columns
    By bigband1 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-18-2012, 09:12 AM
  4. Extract data from text string
    By bigband1 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-24-2011, 04:55 AM
  5. Extract number data string from text
    By lamatao in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-03-2009, 04:27 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