function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Admin User 1137Admin User 1137 

I am merging the Contacts and Leads using the Standard 'Merge Contacts' and 'Find Duplicates' button.

I am merging the Contacts and Leads using the Standard 'Merge Contacts' and 'Find Duplicates' button. After the Contacts or Leads are merged it is getting updated in the Campaign Member object automatically.
Whenever a Campaign Member is updated, i need to update a Custom object. I am stuck here, the Camapign Member updation is not working as a DML operation and so I am not able to update my custom object.
Whenever a lead/contact is merged, the relevant Campaign Member is updated and the campaign member relevant to the lead/contact that was deleted while merging is also deleted. So now i need to delete the custom object record relevant to the deleted campaign member (while merging) and update the custom object record relevant to updated campaign member (while merging). Can anyone help me out with this. ?