G
Guest
I have a txtPhone that I need to format like 555-555-5555 and when a user
inputs numbers it should only take numbers.
inputs numbers it should only take numbers.
Dave said:I have a txtPhone that I need to format like 555-555-5555
and when a user inputs numbers it should only take numbers.
Sooraj PM said:Hi
You mean the text box should display the characters like that? If yes, You
can use the ToString method by giving txtPhone.Text =
MyPhoneNumber.ToString("###-###-####"). While saving replace the "-"
character with null.
Sooraj
Microsoft Community Star