Abdu_Allah
asked on
How to make textbox accept just numbers(from 0 - 9)?
How to make textbox accept just numbers(from 0 - 9)?
Regards.
Regards.
see http://www.eworldui.net/CustomControls/NumericBox.aspx
Imports Microsoft.VisualBasic
Dim MyInt As Integer
If IsNumeric(txtbox.Text) Then MyInt = txtbox.Text
If MyInt >= 0 And MyInt <= 9 Then
'do something
Else
'err msg
End If
Dim MyInt As Integer
If IsNumeric(txtbox.Text) Then MyInt = txtbox.Text
If MyInt >= 0 And MyInt <= 9 Then
'do something
Else
'err msg
End If
ASKER
Actually I want to use a validator control, like comparevalidator.
i think the required field validator allows you to put in a min and max value....
ASKER
I do not want range validation I just want to accept numbers, no aphabatic characters.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
RainMan82... you think bad :)