+ Reply to Thread
Results 1 to 6 of 6

How to take from 5th letter to the front?

  1. #1
    Registered User
    Join Date
    01-20-2009
    Location
    Eua
    MS-Off Ver
    Excel 2003
    Posts
    2

    Question How to take from 5th letter to the front?

    let me explain:

    1 colunn

    234567-roma
    345697-new york
    431414-lancsternshein
    413444-madri

    I need to take the name of the city to another colunn like this:

    1º colunn 2º colunn
    234567 roma

    how I do that?

    thanks

  2. #2
    Forum Expert sweep's Avatar
    Join Date
    04-03-2007
    Location
    Great Sankey, Warrington, UK
    MS-Off Ver
    2003 / 2007 / 2010 / 2016 / 365
    Posts
    3,454
    These formulas will split the data as you have requested.

    =LEFT(A1,FIND("-",A1)-1)

    =RIGHT(A1,LEN(A1)-FIND("-",A1))
    Rule 1: Never merge cells
    Rule 2: See rule 1

    "Tomorrow I'm going to be famous. All I need is a tennis racket and a hat".

  3. #3
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326
    A solution without formulas :
    Data - text to columns
    Select "Delimited"
    Input "-" ( no quotes) as delimiter
    Finish

    ( if you always have 6 numbers followed by the dash, the " Fixed width" option might also do the job but you'll be left with a third column with the dash

  4. #4
    Valued Forum Contributor mudraker's Avatar
    Join Date
    11-10-2003
    Location
    Melbourne, Australia
    Posts
    3,983
    Another option
    Select data
    Data menu
    Text To Columns
    Delimited option
    Tick Other Checkbox & remove tick from all other checkboxes
    enter - in the box to the right of the Other checkbox
    Next
    Set column data format if required
    Finish button
    Please Read Forum Rules Before Posting
    Wrap VBA code by selecting the code and clicking the # icon or Read This
    How To Cross Post politely

    Top Excel links for beginners to Experts

    If you are pleased with a member's answer then use the Scales icon to rate it
    If my reply has assisted or failed to assist you I welcome your Feedback.

  5. #5
    Registered User
    Join Date
    01-20-2009
    Location
    Eua
    MS-Off Ver
    Excel 2003
    Posts
    2
    thanks people,


    Pol

  6. #6
    Valued Forum Contributor mudraker's Avatar
    Join Date
    11-10-2003
    Location
    Melbourne, Australia
    Posts
    3,983
    Your post does not comply with Rule 9 of our Forum RULES. If you solve a problem yourself before anyone else has responded, please take a moment to describe your solution, chances are some other member will benefit. And please never edit a thread in which someone else has responded.

    How to mark a thread Solved
    Go to the first post
    Click edit
    Click Go Advanced
    Just below the word Title you will see a dropdown with the word No prefix.
    Change to Solved
    Click Save

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

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