locked
Assign message issue in plug-in RRS feed

  • Question

  • Hi,

    We are facing some issue with the plug-in that are registered on Assign message. The issue is that plug-in fire twice instead of one so our logic will break and the depth is 1 for both times. So it is vary difficult to identify why it fire and identify it fire in second time.

    Can anyone faced same issue and have any resolution for this issue.

    Waiting for resolution.

    Thanks!

    Balasaheb

    Thursday, November 5, 2015 1:47 PM

All replies

  • I've never come across this happening. Are you sure you've not registered more than one plugin step ?

    If the plugin does genuinely fire twice, with the same data in the InputParameters, then you could try using SharedVariables. The pattern would be:

    • The plugin checks for a SharedVariable of a specific name.
    • If it already exists, exit without doing anything
    • Otherwise, add the SharedVariable, and continue

    Microsoft CRM MVP - http://mscrmuk.blogspot.com/ http://www.excitation.co.uk

    Thursday, November 5, 2015 4:40 PM
    Moderator
  • Hi David,

    We have checked and confirm that we have registered it only one step. We have checked the SharedVariables concept but it did not work because it treated as new pipeline so each time it do not contains SharedVariables that we added into first time when it fires.

    Just to confirm we have checked this on CRM 2015 onprem.

    Can you please let us know if you have any other solution.

    Thanks!

    Balasaheb

    Friday, November 6, 2015 3:22 PM
  • Hi David,

    We have checked and confirm that we have registered it only one step. We have checked the SharedVariables concept but it did not work because it treated as new pipeline so each time it do not contains SharedVariables that we added into first time when it fires.

    Just to confirm we have checked this on CRM 2015 onprem.

    Can you please let us know if you have any other solution.

    Thanks!

    Balasaheb

    I've run into this as well, found no way around it and since it's two separate calls there are no shared variables AFAIK. What are you trying to do? I was able to do it in another way so I didn't have to use the assign call as a trigger which was the only way around this. Very annoying feature from Microsoft.

    Regards


    Rickard Norström Developer CRM-Konsulterna
    http://www.crmkonsulterna.se
    Swedish Dynamics CRM Forum: http://www.crmforum.se
    My Blog: http://rickardnorstrom.blogspot.se

    Friday, November 6, 2015 3:36 PM