-
How to Bypass Merge Operation for this specific scenario? (read description below)
I have a requirement in which system will allow to delete an account only when its related contacts status are inactive...if any of the contacts are active then it should throw an error message.. I have fulfilled this functionality by writing apex code on beforedelete event..My code is working fine but there is a standard functionality in Salesforce called as "Merging"........In that scenario when i merge two accounts,if loosing account contains active records then it is throwing me validation message...but I have to bypass my code when it comes to the merging....
Can anybody suggest me,how I bypass the code?
One thing I tried,note down the masterid of winning record and put in my condition where I can bypass the scenario..but when I merge the accounts then I am not able to get MasterID of Winiing record....I am not sure why this is happening???
Ideally I should get some ID of the merge operation
Log In to reply.
Popular Salesforce Blogs
How to Properly Implement a Salesforce Deduplication Feature: 5 Tips You Need to Follow
If your company is like many others struggling with duplicates in Salesforce, you are actively looking for solutions that can solve this problem. When you…
Salesforce Sales Cloud - The Complete Guide
Introduction As we already know Salesforce CRM helps every industry to win more deals, manage the business efficiently and to build strong relationships with customers.…
Popular Salesforce Videos
Salesforce App Builder Training | Salesforce App Builder Tutorial | Intellipaat
In this salesforce app builder tutorial, you will learn what is Salesforce CRM, a Sales rep in Salesforce, various user settings in Salesforce, and how…
Salesforce Multifactor Authentication Webinar
An extra layer of security on your Salesforce org is always worth it. Learn how to safeguard your sensitive Salesforce account information from unauthorized access…
Pardot Marketing Automation Tools Overview Webinar
Are you looking to take your Salesforce Marketing Automation to the next level? Learn how to build successful lead nurturing campaigns that empower your sales team…