Discussions
How to trigger script when address subrecord is created or changed
Hi all,
I have added a custom field to the address subrecord (working initally with customer records) to capture the lat-long position of each address. I now want to write a script that will trigger when any new address subrecord is created or an existing address subrecord is changed. This script will use a geocoding service to determine the lat long position of the new or updated address and update the custom field.
I'm interested to hear if anyone has ideas around how I would go about this? I dont believe we are able to script directly on the address subrecord but will need to be through the customer record. Is there an easy way I can determine from the customer record (probably in before submit) which (if any) address subrecords have been created/changed?