ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Format a Telephone number (https://www.excelbanter.com/excel-worksheet-functions/247430-format-telephone-number.html)

LeeE

Format a Telephone number
 
I want to format the telephone numbers in my excel file so that all look like
this:
508-567-3992 Eg: ###-###-####
Some have parenthesis around the first 3 digits, some have periods after the
3 digits.
I tried creating a custom type in numbers but I think it needs to be a
formula.

Can anyone help?

Thanks
Lee

Bella Reitano

Format a Telephone number
 
You could use something like:
[Blue](000)_-000-0000
as a custom format. I like the blue because it makes it easier to spot
the failures :)
Note that this format will not like ANY non-digit characters
(including hypens).



On Nov 3, 5:49*pm, LeeE wrote:
I want to format the telephone numbers in my excel file so that all look like
this:
508-567-3992 *Eg: *###-###-####
Some have parenthesis around the first 3 digits, some have periods after the
3 digits.
I tried creating a custom type in numbers but I think it needs to be a
formula.

Can anyone help?

Thanks
Lee



Tom Hutchins

Format a Telephone number
 
Here is one way...

=TEXT(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE( SUBSTITUTE(A1,"
",""),")",""),"(",""),".",""),"-",""),"000-000-0000")

Hope this helps,

Hutch

"LeeE" wrote:

I want to format the telephone numbers in my excel file so that all look like
this:
508-567-3992 Eg: ###-###-####
Some have parenthesis around the first 3 digits, some have periods after the
3 digits.
I tried creating a custom type in numbers but I think it needs to be a
formula.

Can anyone help?

Thanks
Lee



All times are GMT +1. The time now is 08:36 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com