Excel - Parse Column Text

Rickzzz
Rickzzz used Ask the Experts™
on
cell a1 = user@domain.com

I just need the "user" part prior to the @ in another column.

Thanks in advance!
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Professor JMicrosoft Excel Expert
Top Expert 2014

Commented:
two option , first option use text to column

go to data tab then text to column

then your delimited and on the selection unmark all mark "other"  then put @ in that small box and then next and finish.

second Option
if you want to use formula instead of text2column then .  lets say your data starts from cell A2 then put in B2  =TRIM(MID(SUBSTITUTE(A2,"@",REPT(" ",99)),1*99-98,99))  and in C2   =TRIM(MID(SUBSTITUTE(A2,"@",REPT(" ",99)),2*99-98,99)) and drag the formula down
Try this:

A1 = LEFT(B1,FIND("@",B1&"@")-1)

assumes the "user@domain.com" is in cell B1.
Professor JMicrosoft Excel Expert
Top Expert 2014

Commented:
if you just need the first part before @  then you only use this =TRIM(MID(SUBSTITUTE(A1,"@",REPT(" ",99)),1*99-98,99))

Author

Commented:
Perfect, thanks.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial