How to validate non entity fields but just textboxes. Also add dynamic validations

I am new to Silverlight and want to achieve validations.

I have a form with accordion control. I have controls in each section and have to have validations like Required or optional, if given a value it has to be valid like emai, phone number..... All these validations i have Dynamically enable or disable at page load.

So How i can achieve this in Silverlight 4. In simple words how can we have Required field validator, CUstomvalidator and range validators in SilverLight.

I have gone through RIA but i am not sure how to use that on non entity fields and also Dynamically enable or disable validations.

Example i have txtFirstName, txtLastName and txtPhone. I want firstname required and Phone optional but should be validated if given some value.

All these fields are not part of any entity. Where i can add required or other attributes.

Thanks in advance.


You can add context to the validation process and allow your custom validators to be aware of some state. Fore example, you can add your page to the context and the validator can later access it to perform some conditional logic. See "RIA Services Validation: Providing ValidationContext" by Jeff Handley

How Silverlight Validation Works by Shawn Wildermuth.

Need Your Help

Images appear after scrolling table view (AFNetworking)

iphone ios objective-c networking afnetworking

I am using AFNetworking to download images from server , everything works fine but images wont't be appear unless I scroll table view . here is my code :

Converting .ToString([custom format])

c# string string-formatting

How can I achieve formatting string to custom format:

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.