Validating User Input

In addition to accepting input, validating that input is an important function of a data entry program. A typical data entry form contains validation code that must execute successfully before the information can be committed to the database. If the validation tests do not pass, then the program displays a message requesting that the user correct the erroneous data. When you build a form, certain types of controls do not require much or any validation code. For example, in a drop-down list the user is restricted to selecting a fixed set of choices that you, the programmer, control. However, a text box control allows the end user to enter almost any type of numeric or character data. Therefore, more stringent validation ...

Get Special Edition Using Microsoft® Visual Basic® .NET 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.