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
Jason RussoJason Russo 

Is there a way to convert a lead into a custom object?

Best Answer chosen by Jason Russo
Jeremy Thompson 1Jeremy Thompson 1

All Answers

Jeremy Thompson 1Jeremy Thompson 1
This was selected as the best answer
JyothsnaJyothsna (Salesforce Developers) 

You will need to write a trigger on the lead object. There is a flag field "isConverted" on lead to decide whether it is converted. Write a trigger on update event of lead. Compare trigger.Old value and trigger.The new value of isConverted flag. Then you can insert objects as you want.
Please check the below link for more information.
Best Regards,
Becka DBecka D
You could also use Flow to copy all the values from the Lead to your custom object, adn then update the Lead to some sort of 'archived' status. It wouldn't truly be converted, but the same general idea. (Or, I suppose once you copy the values, you could use the flow to delete the lead record too - I'd opt for the first option thought, for auditing.)
Jeremy Thompson 1Jeremy Thompson 1
The app seems like a quick fix. But, if you are set on coding, there's another post here: