+ Start a Discussion
Rodolfo CalvoRodolfo Calvo 

Merge contacts apex method

Hello team,

Is there a good tutorial to make a merge contacts app in apex? 
I have been looking for how to do this. Please could someone explain to me how to make a aplic custom visualforce merge page for contacts or accounts?? 

Thanks in advance! 
Best Answer chosen by Rodolfo Calvo
Rodolfo CalvoRodolfo Calvo
Is there any way to copy all contacts from one account to another? 

All Answers

Hargobind_SinghHargobind_Singh
Hi,

You can use Database.merge() apex function to achieve this. Unfortunately, I don't have any ready code to share, you would need to write a Visualforce page to do this. I found a mockup that someone built here: https://code.google.com/p/npsp/wiki/ContactMerge

And you can find some help here for merge (and other DML functions): https://developer.salesforce.com/trailhead/apex_database/apex_database_dml


 
Rodolfo CalvoRodolfo Calvo
Is there any way to copy all contacts from one account to another? 
This was selected as the best answer