This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
I am assuming that Entity.IsValid would work recursively on all child attributes of type Entity. Is this correct? UserProfile myProfile = new UserProfile(); if( myProfile.IsValid ) Do I need to call myAddress.IsValid and get myAddress.Errors explicitly? Johannes |
|
|
Hi Johannes, At the moment you need to validate the child object manually. However, I'm looking at putting in the automatic validation for the next release. The easiest way to do the validation at the moment is to override Entity.OnValidate and validate child objects there. That way you can add any child validation errors to the parent Errors collection if that is appropriate. Cheers, Andrew.
|
|