Click here to Skip to main content
14,455,922 members
Rate this:
Please Sign up or sign in to 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, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100