Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

3. Advanced Data Binding > Validating data-bound input

Validating data-bound input

Applies to Silverlight 3, 4 and 5

Validation of your data is a requirement for almost every application. By using validation, you make sure that no invalid data is (eventually) persisted in your data store. When you don't implement validation, there is a risk that a user will input wrongly-formatted or plain incorrect data on the screen and even persist this data in your data store. This is something you should definitely avoid.

In this recipe, we'll learn about implementing client-side validation on the bound fields in the UI.

Getting ready

To get ready for this recipe, you can either use the code from one of the previous recipes or use the provided starter solution in the Chapter03/SilverlightBanking_Validation_Starter folder in the code bundle available on the Packt website. The complete solution for this recipe can be found in the Chapter03/SilverlightBanking_Validation_Completed folder.


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial