Skip to main content
Hi Guys,

I have a custom Convert button in Leads which converts Leads to Account, Contact & Opportunity mapping to custom fields. 

Can you please advise what the formula is if I want to map Lead Currency to the Account Trading Currency field ONLY where a new Account is created upon conversion. I also want to map the address from the lead from existing accounts to overwite the invoice address in Accounts.  Is it possible to do this in the custom button or will I need to write a trigger / class to perform this action ?

My current button is reads

/lead/leadconvert.jsp?&id={!Lead.Id}&noopptt={!Lead.Name}&00ND0000004zxhO="Inbound"&id={!Lead.Id}&IsReminderSet_fu=0

&00ND0000005aKus={!Lead.PProfile1__c}&id={!Lead.Id}

&00ND0000005aKv7={!Lead.PProfile2__c}&id={!Lead.Id}

&00ND0000005aKvC={!Lead.PProfile3__c}&id={!Lead.Id}

&00ND0000005aKvH={!Lead.PProfile4__c}&id={!Lead.Id}

&00ND0000005aKvM={!Lead.PProfile5__c}&id={!Lead.Id}

&Amount={!Lead.Invoice_Sub_Total__c}&id={!Lead.Id}

&00ND0000005absU={!Lead.CurrencyIsoCode}&id={!Lead.Id}

&BillingAddress={!Lead.Mailing_Street__c},{!Lead.Mailing_City__c},{!Lead.Mailing_Country__c},{!Lead.Mailing_Zip_Postal_Code__c}&id={!Lead.Id}

Please advise.

Thanks in advance

Robeela
4 answers
  1. Nov 9, 2016, 12:47 PM
    Hi Robeela,

    Please find the information below.

    Description:

    By default, the standard Lead Source field on the Lead object is not mapped automatically to the Account Source field on the Account object when converting a lead. We'll show you how to use custom fields and Workflow Rules to accomplish this mapping.

    Resolution:

    1. Create a Lead Custom Field with a return type of Text:

    • Field Name = Lead Source Text (Hidden)

    This field shouldn't be on any lead page layout

    Note: To reduce the number of work flow used for Leads Object. You can just create a custom Formula Field on Leads that copy the value of the Lead Source field.

    Formula is TEXT(LeadSource)

    Then map the custom formula field to the Account Text field that needs to be created. 

    This way, a workflow on Leads object can be avoided and Step 4 and 5 will be removed.

    2. Create an Account custom Text field:

    • Field Name = Account Source Text (Hidden)

    You'll need to specify the length accordingly (255 max is recommended). Also, this field shouldn't be on any page layout.

    3. Setup Lead field mapping:

     

    1. Go to Setup.

    2. Under Build, click Customize | Leads | Fields.  

    3. Under "Lead Custom Fields & Relationships," click the Map Lead Fields button.

    4. Map the new "Lead Custom Text Field" to the new "Account Text field."

     

    4. Create a Workflow Rule on Leads with the Rule Criteria:

    Lead Source Text (Hidden)    EQUALS   Blank.

     

    5. Add a "Field Update" to "Update the Lead Source Text (Hidden) Field" with the Name of the Lead Source Text.

    6. Create a workflow rule or process builder on Accounts with the Rule Criteria:  

    • Account Source Text (Hidden) equals Lead Source Value.

    You'll need to build 1 workflow rule for each Lead Source Value you have that'll need to update the standard Lead Source field. The Evaluation Criteria should be set to trigger when a record is created.

    7. Add a field update to your workflow that'll update the standard Account Source field to the appropriate value.

     

    Now whenever a Lead is converted going forward the Account should be assigned the same Account Source as that of the Lead. You'll need to repeat steps 6 and 7 every time you create a new Lead / Account source in the future.

    Kindly mark this post as solved if the information help's so that it gets removed from the unanswered queue and becomes a proper solution which results in helping others who are really in need of it.

    Best Regards,

    Nagendra.P
0/9000