+ Reply to Thread
Results 1 to 9 of 9

Separate address into separate lines WITHIN a cell

  1. #1
    Registered User
    Join Date
    08-21-2012
    Location
    East Coast, US
    MS-Off Ver
    365 and Desktop
    Posts
    57

    Separate address into separate lines WITHIN a cell

    Hi,
    I have a bunch of addresses in rows of single lines in one cell. I need A1 to become B1 without having to manually do it by hitting ALT + ENTER to go to the next line within each cell.

    -see attachment-

    Thanks for your help!
    Attached Images Attached Images
    Attached Files Attached Files
    Last edited by asabur6; 07-19-2021 at 11:10 AM.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2507 (Windows 11 Home 24H2 64-bit)
    Posts
    91,800

    Re: Separate address into separate lines WITHIN a cell

    One example is never going to be enough.

    There are instructions at the top of the page explaining how to attach your sample workbook.
    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. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Separate address into separate lines WITHIN a cell

    Assuming that the town name is always a single word (big assumption)
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    The cell with the formula must be formatted to wrap text.
    If you are going to have town names with spaces, you need to come up with some logical way for Excel to be able to know where to place the line break.
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  4. #4
    Registered User
    Join Date
    08-21-2012
    Location
    East Coast, US
    MS-Off Ver
    365 and Desktop
    Posts
    57

    Re: Separate address into separate lines WITHIN a cell

    Hi Ali,
    I have reposted with the spreadsheet attached instead of an image.
    However, I must admit that Iam confused. In "Manage attachments" there are plenty of image extensions listed as acceptable. But under "HOW TO ATTACH YOUR SAMPLE WORKBOOK:" it says "Post a small Excel sheet (not a picture)" How do I know when/or if an image is acceptable or not? I guess when you all would need to "play around" with our data to come up with solution?

    Thanks

  5. #5
    Registered User
    Join Date
    08-21-2012
    Location
    East Coast, US
    MS-Off Ver
    365 and Desktop
    Posts
    57

    Re: Separate address into separate lines WITHIN a cell

    Thanks ChemistB,
    That got me mostly where I need to be. It worked for alot of addresses. However, a space between a city name is not necessarily the only problem. I need 2 breaks (after the street AND after the State). I need help with that and dont even know where to begin to "come up with some logical way for Excel to be able to know where to place the line break."

  6. #6
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Separate address into separate lines WITHIN a cell

    Is it possible to have a list of all the towns (in a single column) somewhere (on sheet2, i.e. )? Otherwise, no way for Excel to know where the street name ends and the town/city begins.

    Here is the original formula updated to move the zip code to a new line (fyi, your example has it on the same line as the state and city)
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    08-21-2012
    Location
    East Coast, US
    MS-Off Ver
    365 and Desktop
    Posts
    57

    Re: Separate address into separate lines WITHIN a cell

    Thanks, this one worked best! Very much appreciated!

  8. #8
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Separate address into separate lines WITHIN a cell

    With a list of all the towns/cities in sheet2!A1:A17, this formula takes into account spaces in town names

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    I used it in column D
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    08-21-2012
    Location
    East Coast, US
    MS-Off Ver
    365 and Desktop
    Posts
    57

    Re: Separate address into separate lines WITHIN a cell

    Thanks again!

+ 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. Replies: 5
    Last Post: 04-09-2020, 09:39 AM
  2. Replies: 11
    Last Post: 03-01-2019, 01:17 PM
  3. [SOLVED] Separate a statement that utilizes Split(), into 2 or more separate lines.
    By excelicus in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-15-2018, 05:17 AM
  4. Separate Multiple Lines in 1 Cell
    By SpanishMosca in forum Excel General
    Replies: 3
    Last Post: 12-08-2011, 08:51 PM
  5. How to separate address now in 1 cell into 4 cells
    By Launchnet in forum Excel General
    Replies: 1
    Last Post: 09-10-2010, 12:22 AM
  6. Separate Address from Cell
    By mpquin in forum Excel General
    Replies: 2
    Last Post: 01-26-2010, 03:50 PM
  7. [SOLVED] separate address data in a cell
    By Joe in CT in forum Excel General
    Replies: 2
    Last Post: 03-18-2006, 10:00 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