String

A

Access Front End

Hi Anyone!

How do you FIND a string in a cell. I know that in C language you can use
"string" but what do you use in Excel. I have a cell that contain First name
then comma some time a space then Last Name. How can I get the Firstname in
one column & Last name in one column by using the formula. Thanks

Ngan
 
K

Kevin Lehrbass

Hi Ngan,

I have a free download on my website which shows you have to do this. There
are also many other excel websites with text formulas and text downloads. Do
a search "excel separate lastname, firstname".

Cheers,
 
B

Bob Phillips

=LEFT(A1,Find(" ",A1)-1)
and
=RIGHT(A1,LEN(A1)-FIND(" ",A1)-1)

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)
 
K

Kevin Lehrbass

Hi Again,

I found the formula for you.
Extract last word: =RIGHT(A1,LEN(A1)-FIND(" ",A1,1))
Extract first word: =LEFT(A1,FIND(" ",A1)-2)
 
B

B. R.Ramachandran

Hi,

If a comma separates the first and last names, and also some entires contain
a space after the comma, use the following formulas in B1 and C1 to extract
the first and last parts respectively (change the 'A1's appropriately).

=LEFT(A1,FIND(",",A1)-1)
=TRIM(RIGHT(A1,LEN(A1)-FIND(",",A1)))


Regards,
B. R. Ramachandran
 
A

Access Front End

Thank You ALL

Ngan

B. R.Ramachandran said:
Hi,

If a comma separates the first and last names, and also some entires contain
a space after the comma, use the following formulas in B1 and C1 to extract
the first and last parts respectively (change the 'A1's appropriately).

=LEFT(A1,FIND(",",A1)-1)
=TRIM(RIGHT(A1,LEN(A1)-FIND(",",A1)))


Regards,
B. R. Ramachandran
 
Top