O'Reilly logo

Windows® Phone 8 Unleashed by Daniel Vaughan

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

Performing Group Validation

Validating a series of input fields usually entails validating each field as the user leaves the field, and then checking for completeness and validity of all fields when the Submit button is tapped (see Figure 26.7).

Image

FIGURE 26.7 Form validation activity diagram.

The UpdateSource method of the BindingExpression class can be used to validate all controls on a form. As you saw in the preceding section, the UpdateSource method causes the target value to be reassigned to its source property. In other words, the value in the control is pushed to its data context, allowing the discovery of any input validation errors.

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