Click here to Skip to main content
15,886,518 members
Please Sign up or sign in to vote.
2.00/5 (1 vote)
See more:
In my windows form I have an area for the user to enter a phone number (American).
There are many different way to display this info...
(###) ###-####
###.###.####
#-###-###-#### x### (where x is an extension)

How can I force the input, no matter what the user types or pastes, to be in the format of '###-###-####'? If there is an extension it could be added at the end in format 'x###', but is not necessary.
Posted
Comments
Maciej Los 15-May-15 15:41pm    
Sean, what you mean by saying "extension"?

1 solution

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900