This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

When does value template get triggered?

Hi,

We are working with Value Templates and would like to know under what all conditions does a template get triggered and where can we change that, if possible?

For example, the template for Person.CentralAccount makes use of Person.FirstName and Person.LastName. If the value of LastName for an employee is changed, the value for CentralAccount changes. Which means that the template for Person.CentralAccount is executed if LastName or FirstName is changed. Can we prevent the CentralAccount template from executing on change of FirstName and LastName? How can we do this?

Thanks for your help in advance.

Parents
  • Hi,

    All templates are triggered based on changes to referenced attributes.  This includes attributes that are explicitly referenced (using the $ notation) and even attributes referenced in VB.Net comment lines (prefixed by a ' [single quote]).

    If you want the template to only fire once and never again, then uncheck the 'overwrites' checkbox.

    But be aware ... you may get some undesired side effects .... for example if the template builds centralaccount from firstname and lastname ..... it may only trigger when one of the attributes is populated and it may not trigger again when the other attribute is populated.  You'll have to figure this out in testing.


    HTH, Barry.

Reply
  • Hi,

    All templates are triggered based on changes to referenced attributes.  This includes attributes that are explicitly referenced (using the $ notation) and even attributes referenced in VB.Net comment lines (prefixed by a ' [single quote]).

    If you want the template to only fire once and never again, then uncheck the 'overwrites' checkbox.

    But be aware ... you may get some undesired side effects .... for example if the template builds centralaccount from firstname and lastname ..... it may only trigger when one of the attributes is populated and it may not trigger again when the other attribute is populated.  You'll have to figure this out in testing.


    HTH, Barry.

Children
No Data