How to parse email address to columns

Sir Vili

Board Regular
Joined
Jul 11, 2002
Messages
148
Hello everybody.

Problem:

How to parse email address to columns with formulas?

Example (imaginary):
In A1 there is kit.carson@wildwest.com

I want in B1 kit; C1 carson; D1 wildwest That D1 must be without .com

Sir Vili.
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
Hi Sir Vili,

These formulas should work

Cell B1
=LEFT(A1,SEARCH(".",A1,1)-1)

Cell C1
=MID(A1,SEARCH(".",A1,1)+1,((SEARCH("@",A1,1)-1)-SEARCH(".",A1,1)))

Cell D1
=MID(A1,SEARCH("@",A1,1)+1,SEARCH(".",A1,SEARCH("@",A1,1))-1-SEARCH("@",A1,1))

Please note - I have only tested them on the email format you have supplied. If you have any other formats ( e.g. name@company.com ; first.last@site.company.co.uk etc ) then you will need other formulas. If there are a lot of different amila address ormats then I'd suggest using a VB script to check the format & then apply the correct sets of formulas.

HTH,

Iain
 
Upvote 0
Hello Iain.

I appreciate Your solution. These formulas suits for my use at the moment.

Thank You very much.

Best Regards Sir Vili.
 
Upvote 0
Sir Vili,

Something else you could do, a 2 step process manually, is to select your cell with the e-mail address. From there select Text to Columns from the data menu. Type in a decimal (.) in the "other" delimiter field. You can change the destination to the cell beside the original if you want to maintain the source. This will parse in to (3 in this case) columns.

Repeat the process and change the delimiter to the @ sign. In my try, i left the destination as the same cell and overwrote the cell containing the com entry as you indicated you did not want the com in the output.

If you recorded a macro to perform both steps, you could automate the process greatly and have it available at any time.

HTH, Regards
Tom
 
Upvote 0
On 2002-09-06 00:57, Sir Vili wrote:
Hello everybody.

Problem:

How to parse email address to columns with formulas?

Example (imaginary):
In A1 there is kit.carson@wildwest.com

I want in B1 kit; C1 carson; D1 wildwest That D1 must be without .com

Sir Vili.

If you installed the great morefunc add-in:

In B1 enter:

=WMID(A1,1,1,".")

In C1 enter:

=WMID(SUBSTITUTE(A1,"@","."),2,1,".")

In D1 enter:

=WMID(SUBSTITUTE(A1,"@","."),3,1,".")
 
Upvote 0
Hi Tom@CPC.

Excellent idea. Worked fine. Thank You very much.

Hi Aladin.

I checked now in my home Your formulas and found then easy to use. Thank You again helping me and giving varieties to solve problems with formulas. I like it.

Best regards to both.
Sir Vili.
 
Upvote 0

Forum statistics

Threads
1,214,606
Messages
6,120,497
Members
448,967
Latest member
visheshkotha

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top