You need to sign in to do that
Don't have an account?
Akshay Shrivastava
how to get data from contact
I have a custom object.
if Name field of Custom object is same as the name field of Contact object.then email of that contact should be in custom object email field
if Name field of Custom object is same as the name field of Contact object.then email of that contact should be in custom object email field
I am assuming there are unique contact names and the duplicate rules are active under the contact object. Please make appropriate changes as needed.
Let me know if it helps you and close your query by marking it as the best answer so that it can help others in the future.
Thanks.
All Answers
You can have a trigger on the custom object and implement it like below:
Please note you need to modify it to fit your needs and you need to modify names as present in your org.
Additionally, I would suggest you to have a look at the best practices as well: https://developer.salesforce.com/forums/?id=906F0000000DBl8IAG
Let me know if it helps you and close your query by marking it as solved so that it can help others in the future.
Thanks.
then
If two contacts have the same name then out of 2 which contact email should be populated in the email field of the custom object?
Thanks & Regards
Suraj Tripathi
I am assuming there are unique contact names and the duplicate rules are active under the contact object. Please make appropriate changes as needed.
Let me know if it helps you and close your query by marking it as the best answer so that it can help others in the future.
Thanks.