+ Reply to Thread
Results 1 to 4 of 4

Carriage Returns

  1. #1
    Registered User
    Join Date
    07-25-2008
    Location
    London
    Posts
    8

    Carriage Returns

    Hi,

    Just wondering if someone could help me. I have a cell whereby I have an address. The address is split into 4 lines. Is there anyway I can copy each line to a new cell e.g

    if Address is in A1, top line goes to B1, 2nd line to C1, etc

    Any help would be greatly appreciated

    Regards

    Robert

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Carriage Returns

    Mockup a sample workbook showing a few rows of the data and your desired results, point out where the results came from if not obvious in your sample data.

    Click GO ADVANCED and use the paperclip icon to post up your workbook.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Registered User
    Join Date
    07-25-2008
    Location
    London
    Posts
    8

    Re: Carriage Returns

    Quote Originally Posted by JBeaucaire View Post
    Mockup a sample workbook showing a few rows of the data and your desired results, point out where the results came from if not obvious in your sample data.

    Click GO ADVANCED and use the paperclip icon to post up your workbook.
    I have attached a file, A1 is the cell I have, A5 is what I would like to appear

    Thanks
    Attached Files Attached Files

  4. #4
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Carriage Returns

    In B1:
    =LEFT($A1, FIND(CHAR(10),$A1)-1)

    In C1:
    =MID($A1,FIND(CHAR(10),$A1)+1,FIND(CHAR(10),SUBSTITUTE($A1,CHAR(10),"|",1)) - FIND(CHAR(10),$A1))

    In D1:
    =MID($A1,FIND(CHAR(10),SUBSTITUTE($A1,CHAR(10),"|",1))+1,LEN($A1))

+ 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