capturing phone numbers help

  • Thread starter Thread starter Mark
  • Start date Start date
M

Mark

I can't figure out how to use @Text properly.

Lets say A1 has text of (318) 123-4567

and I want to put a formula in A2 to capture only the numbers and store them
as 3181234567 in A2.

A1 is not formatted, its just text.

This can't be very hard, how to do??
Thx mucho !!

Mark
 
Try this formula:
=text (concatenate(mid(A1,2,3),mid(A1,6,3),right(A1,4)),"0000000000")
 
or
=SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(B2,"(",""),")",""),"
",""),"-","")
 
I can't figure out how to use @Text properly.

Lets say A1 has text of (318) 123-4567

and I want to put a formula in A2 to capture only the numbers and store them
as 3181234567 in A2.

A1 is not formatted, its just text.

This can't be very hard, how to do??
Thx mucho !!

Mark

If you happen to have Longre's free morefunc.xll add-in, available at
http://xcell05.free.fr/

you could use the simple formula:

=REGEX.SUBSTITUTE(A1,"\D")

This will remove every character that is not a digit.




--ron
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top