You need to sign in to do that
Don't have an account?
Vinicius Vandre 5
How to set custom field values in Account for Lead conversion ?
I'm trying to use Database.leadConvert to set Account fields based on a condition, as such:
Database.LeadConvert lc= new Database.LeadConvert();
lc.setLeadId(lead.Id);
lc.setConvertedStatus('Closed-Converted');
lc.accountrecord.CustomField = 'Value';
Database.leadConvertResult lcr = Database.convertLead(lc);
However I get a "Variable does not exist: CustomField" Error.
How would I go about achieving the task using Database.LeadConvert class?
Huge thanks in advance
Check below reference that can help you.
https://salesforce.stackexchange.com/questions/370449/how-to-set-custom-field-values-in-account-for-lead-conversion
Hope above information was helpful.
Please mark as Best Answer so that it can help others in the future.
Thanks,