How to trigger validation on a new property (based on a property on the entity model) in the developer class respresenting a DF entity?
For example, how to trigger validation on the "NameCustom" property in the following scenario? Using AddTrigger("NameCustom") does not fire the delegate validation function after hitting the setter for NameCustom (checked using the debugger). In the verifier collection (during debug), I do see a verifier with TriggerItem set to "NameCustom".
If I set the trigger for "Name", it works fine. Do I need to decorate the developer class or NameCustom property with any attributes so that the VerifierEngine can detect the trigger set for NameCustom?
I could not find any documentation or sample in this regard.
Please let me know if I need to post this as a seperate issue.
Thanks
/* ...IB.Designer.cs */
public partial class Employee : Entity
{
....
public override string Name
get { return PropertyMetadata.Name.GetValue(this); }
set { PropertyMetadata.Name.SetValue(this, value); }
}
/* The developer class representing the Employee business object */
public partial class Employee : Entity
{
....
public override string NameCustom
get { /* custom getter based on Name property */ ... ; }
set { /* custom setter based on Name property */ ... ; }
}