Using the ValidationSummary
Control
The ValidationSummary
control enables you to display a list of all the validation errors in a page in one location. This control is particularly useful when working with large forms. If a user enters the wrong value for a form field located toward the end of the page, the user might never see the error message. If you use the ValidationSummary
control, however, you can always display a list of errors at the top of the form.
Each of the validation controls includes an ErrorMessage
property. We have not been using the ErrorMessage
property to represent the validation error message. Instead, we have used the Text
property.
The distinction between the ErrorMessage
and Text
property is that any message that you ...
Get ASP.NET 4 Unleashed 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.