Forum Discussion
Problems with formating text within a cell.
how can i change 999-999-9999 to 999999999
2 Replies
- Haytham AmairahSilver Contributor
Hi,
The solution depends on the datatype of the number (999-999-9999) in the cell.
If it's a text string, which means that the dashes are really part of it, then you can use the formula suggested by Damien_Rosario to remove them.
But if these dashes are just a format to this number, you can go to the Format Cell (Ctrl+1) to change the format to General or Number.
Hope that helps
- Damien_RosarioSilver Contributor
Hi Kyle_S365
Try:
=SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(G6,"(",""),")",""),"-","")," ",""),".","")+0
Change G6 to whatever cell has the number in it.
Here's the website I found the answer on if you need an explanation and info.
https://exceljet.net/formula/clean-and-reformat-telephone-numbers
I hope that this is your answer. Best wishes!
Cheers
Damien