0

I have a workflow that create a lead and a linked campaign members into a campaign . The fact is this flow come from a package i can't change it (lead capture). I want after the creation change the campaign of the created campaign members but the problem is the field CampaignId is not writeable, when i clone the camapign members to update it the campaign memebers can't be modified because he can't point to a converted lead ...

someone have an idea ?

1 Answer 1

0

Assuming that you can't configure the package to specify the desired campaignId ...

Each CampaignMember has two fields:

  • ContactId
  • LeadId

When you clone the CampaignMember,

  • Set LeadId to the clone source LeadId if the Lead is not converted, otherwise, set to NULL
  • If the clone source's Lead is converted, then query that converted Lead to find its Lead.ConvertedContactId. Use that value to set the cloned CampaignMember.ContactId
2
  • thanks but my client have a lot of dev that use the fields LeadId . I think the best way is to clone lead and campaign May 1 at 10:08
  • Ok, but why clone a converted lead into an unconverted lead? Perhaps I don’t understand your business problem as described.
    – cropredy
    May 1 at 13:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.