O'Reilly logo

ASP.NET by Example by Steven A. Smith

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CompareValidator Control

Often the validity of an item on a form can only be determined based on its relationship to other values on the form. For example, a form might ask the users how much money they would like to donate to a charity, and then ask them how much of their donation they would like to put toward, say, .NET programming training (it could happen…). It wouldn't make any sense for the second value to exceed the first value because it is limited by the total amount the user has donated. In situations like these, the CompareValidator can be used to ensure that the relationships between controls on a form are valid. Table 8.5 describes the properties that make the CompareValidator different from the BaseValidator class discussed earlier. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required