O'Reilly logo

Pro Silverlight 5 in VB by Matthew MacDonald

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

Validation

When the Silverlight data-binding system encounters invalid data, it usually ignores it. For example, consider the following list, which details the three types of errors that can occur when you're editing a two-way field:

  • Incorrect data type: For example, a numeric property like UnitCost can't accommodate letters or special characters. Similarly, it can't hold extremely large numbers (numbers larger than 1.79769313486231570E+308).
  • Property setter exception: For example, a property like UnitCost may use a range check and throw an exception if you attempt to set a negative number.
  • Read-only property: This can't be set at all.

If you run into these errors, you're likely to miss them, because the Silverlight data-binding system doesn't ...

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