-
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
What is Pardot? What is Engagement History in Salesforce in 2023?
Pardot is a software as a service (SaaS) marketing automation platform by SalesForce offering email automation, targeted email campaigns, and lead management for B2B sales…
How Does AI In Salesforce Enable Users and Businesses to Meet Their Goals?
People who work in businesses have goals. The same goes for people who use the software. Organizations try to help their businesses meet their goals…
Introduction to Aura Components in Salesforce - Learn Here
In this blog, we are going to study the topic of Aura Components in Salesforce. Let's begin with the Aura Components programming model: provides out-of-the-box…
Popular Salesforce Videos
Meet us at Dreamforce23 - Unleash the Ultimate Business Experience!
Dreamforce 2023 at San Francisco. Save the dates of September 12–14, 2023, and prepare for an unforgettable experience at Dreamforce 2023. Reserve your position by…
The World of Salesforce Einstein
Salesforce Einstein is artificial intelligence (AI) technology that has been developed for the Salesforce Customer Success Platform. ... Upgrades include Einstein Vision, which brings image…
Custom Aura Feed Component | forceChatter:feed | Chatter in #Salesforce | Salesforce Tutorials
In this vlog I will create a custom aura feed component with two picklists to select Group and then based on the Group selection, select…