+ Reply to Thread
Results 1 to 5 of 5

Extract text before @ sign

  1. #1
    Registered User
    Join Date
    08-13-2012
    Location
    istanbul
    MS-Off Ver
    mac office 2011
    Posts
    3

    Smile Extract text before @ sign

    Hello everyone. Its nice to be here. The case that brought me here is about my mailing lists. There are mails that I dont have names on my mailing list. I have a trick for this. But need VBA help for realisation.

    On a csv file, lets say we have 5000 mails on column A. [email protected] is one them. Our macro should extract 'purple' from '[email protected]' and insert a blank column before email column and enter words to this new column that are extracted from the email addresses.

    That will give me option to say Hello Purple... Capitalizing first letter also would be great.

    Thank you all.

  2. #2
    Valued Forum Contributor tlafferty's Avatar
    Join Date
    04-08-2011
    Location
    United States, Tacoma, WA
    MS-Off Ver
    Excel 2010, Excel 2013 Customer Preview
    Posts
    1,112

    Re: Extract text before @ sign

    You don't need VBA to do this. Insert a blank column before column a and enter the following formula:
    =PROPER(LEFT(b1,SEARCH("@",b1,1)-1))
    If your question has been satisfactorily addressed, please consider marking it solved. Click the Thread Tools dropdown and select Mark thread as solved.
    Also, you might want to add to the user's reputation by clicking the star icon in the lower left corner of the post with the answer- it's why we do what we do...

    Thomas Lafferty
    Analyst/Programmer

  3. #3
    Registered User
    Join Date
    08-13-2012
    Location
    istanbul
    MS-Off Ver
    mac office 2011
    Posts
    3

    Re: Extract text before @ sign

    This is very practical. But how can I implement this to entire column in a practical way besides pulling the selection to the bottom of the 5000th row. Thank you.

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Extract text before @ sign

    Double-click the fill handle at the bottom right of the cell.
    Entia non sunt multiplicanda sine necessitate

  5. #5
    Registered User
    Join Date
    08-13-2012
    Location
    istanbul
    MS-Off Ver
    mac office 2011
    Posts
    3

    Re: Extract text before @ sign

    Thank you.

+ 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