+ Reply to Thread
Results 1 to 2 of 2

Translation of Formula

  1. #1
    Registered User
    Join Date
    12-06-2012
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    14

    Translation of Formula

    Hi, I found a formula that has helped me seperate e-mails into first name and second name.

    For e-mails such as [email protected]



    FIRST NAME: =PROPER(LEFT(A1,MIN(FIND({"@","."},A1&"@."))-1))
    SECOND NAME: =PROPER(REPLACE(LEFT(A1,FIND("@",A1&"@")-1),1,LEN(B1)+1,""))

    I have made a vow to myself to try and understand each formula when I've used them.

    I understand most of the functions used, but I would love a translation of how it works, I don't understand the A1, MIN bit of the first formula.

    I would really love to understand the grammar of these formulas so I can start writing my own.

    Thanks,

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

    Re: Translation of Formula

    [email protected]

    PROPER(LEFT(A1,MIN(FIND({"@","."},A1&"@."))-1))

    FIND({"@","."}, A1&"@." returns the location of the first @ and the first "." The Min returns the smaller of the two numbers. So if your email did not have a period before the "@", this would return everything to the left of the "@" If all of your emails are of the type firstname.secondname, you wouldn't need the MIN and could simplify this to;

    PROPER(LEFT(A1,FIND(".",A1&"."))-1))

    Do you have questions on the second one? Does that explain the first well enough?
    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

+ 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