Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

How to create an event handler when a lead is qualified in Javascript

Posted on by 550

Hi, 

I want to run a javascript code when a lead gets qualified into opportunity , to get the lead values into opportunity record ..I it possible create an event handler on qualification of a lead ..? if so what are the possible ways?

Thanks,

Hajira

*This post is locked for comments

  • Suggested answer
    gdas Profile Picture
    gdas 50,085 on at
    RE: How to create an event handler when a lead is qualified in Javascript

    Hello Roshan ,

    I think you should use field mapping in this case instead of writing javascript as dynamics crm OOB  field mapping are applicable only when you are copying data  from first entity to second entity. Here is some references which will definitely help you.

    community.dynamics.com/.../mapping-lead-data-to-new-opportunities-in-dynamics-365-crm

    itsolutions.bdo.ca/.../using-field-mapping-in-microsoft-dynamics-crm-to-copy-data-between-associated-records

  • Suggested answer
    a33ik Profile Picture
    a33ik 84,323 Most Valuable Professional on at
    RE: How to create an event handler when a lead is qualified in Javascript

    Hello Hajira,

    You don't need any single line of code to transfer data between lead and opportunity - you have mapping for it. Check this article - ledgeviewpartners.com/.../mapping-lead-data-new-opportunities-dynamics-365crm

  • Suggested answer
    Alex Fun Wei Jie Profile Picture
    Alex Fun Wei Jie 33,626 on at
    RE: How to create an event handler when a lead is qualified in Javascript

    Hi ,

    You can create a workflow / field mapping to do that. It is easier than using JS. Make sure the field type is same between lead and opportunity.

    Field mapping

    https://community.dynamics.com/crm/b/crmtipstricksnewstomaster/archive/2017/01/17/mapping-lead-data-to-new-opportunities-in-dynamics-365-crm

    Workflow

    [View:/cfs-file/__key/communityserver-discussions-components-files/117/3480.24.png]

    [View:/cfs-file/__key/communityserver-discussions-components-files/117/2476.25.png]

    Additional

    use workflow when you have conditional mapping else go for field mapping

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans