I'm having trouble with validating my textbox.
My textbox should only accept decimal number, and should not accept negative number.
i tried this code for validating the input type, but i fail.
If Not Char.IsDigit(numWeight.Text) Then
MsgBox("Incorrect input.")
End If
And i don't know if this is the right code for validating for negative numbers.
If numWeight.Text.StartsWith("-") Then
MsgBox("Invalid weight.")
numWeight.Clear()
End If
Please guys need help. Thank you, and God bless.