I’m working on an ASP.NET web project using VS2010/C#, I have some text boxes which users should enter only numbers in them, how can I prevent users from entering non-numeric, floating point numbers and negative numbers in my text boxes? of course I can check entered numbers in server side code, but I think sending data to server and performing validation will take a huge amount of time, is there a way to prevent users from entering non-numeric values? or at least not sending data to server with incorrect data?
thanks
Simply use some javascript and apply to the text box required, then it will not allow the others except numbers, see the following code part.
EDIT: