Thank you for supporting the Cloud Customer Connect Community in 2024. It's a gift to work with you!

Look back
You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Update Contact Address via Field trigger

edited Dec 30, 2021 5:59AM in Sales 5 comments

Summary:

We have a requirement to update the Contact Address based on account associated with the Contact.

Content (required):

We have a groovy to do this. There is no issue when we select account for first time. The address of account is stamped on contact. But, when we change the account, address is not getting updated. Same script works in Before Update trigger but not in Field trigger.

Also what is the best way to remove address. If we remove account from Contact, then the contact address should be null.

Version (include the version you are using, if applicable):


Code Snippet (add any code snippets that support your topic, if applicable):

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!