vb.net 2010 - Text box to accept only numeric values -
text box accepts numeric values. have text box bank account number. want text box accept numeric values.
`private sub data_keypress(sender object, e keypresseventargs) handles data.keypress if (not e.keychar = chrw(keys.back) , ("0123456789.").indexof(e.keychar) = -1) or (e.keychar = "." , data.text.tochararray().count(function(c) c = ".") > 0) e.handled = true end if end sub
`
Comments
Post a Comment