Categories: MSDN / DotNet / Java / Scripts / Linux / PHP Ask - La ask - La Answer

Help with Function

i gotta write a function that will take the "-" off from a textbox when the user input a phone #. so for example
if a user enter 22-424-44 it should show 242444 in the textbox.
thanks
[191 byte] By [gizmo12345] at [2007-11-11 10:29:45]
# 1 Re: Help with Function
Private Sub TextBox1_Validating(ByVal sender As Object, _
ByVal e As System.ComponentModel.CancelEventArgs) _
Handles TextBox1.Validating

StripHyphens(TextBox1)

End Sub

Private Sub StripHyphens(ByVal txtBox As TextBox)
txtBox.Text = Replace(txtBox.Text, "-", "")
End Sub
Phil Weber at 2007-11-11 20:47:33 >
# 2 Re: Help with Function
thanks for the fast reply.
thanks phil
gizmo12345 at 2007-11-11 20:48:39 >