Examining the Need for User Input Validation
In the past two hours, we've examined a number of ways to collect user input. In Hour 10, “Using Textboxes to Collect Input,” we saw how to use the TextBox Web control to collect text input; in Hour 11, “Collecting Input by Using Drop-down Lists, Radio Buttons, and Checkboxes,” we saw how to use DropDownList, RadioButton, and CheckBox Web controls to collect user input that was restricted to one or more items from a predefined list of items.
Typically, when collecting user input, we want the input to be in a certain format or conform to some set of guidelines. Input validation is the process of ensuring that the data entered by a user is in the proper format or meets certain constraints.
For example, ...
Get SAMS Teach Yourself ASP.NET in 24 Hours now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.