Run Workflows on Create of a User in Dynamics 365

Zoe Sands, 19 November 2018

As mentioned in a previous blog, plugins are not triggered on create of a user in CRM 365 online. In that blog, I talked about how you can trigger them on associate of a user to a security role. In this blog, I will talk about another alternative.

When you create a user in CRM online, plugins are not triggered, BUT workflows registered on create of a user are! By registering a workflow on create of a user we can either manage our plugin logic through workflow configuration making it easier to create and deploy small changes to logic without much disruption to your users. Alternatively, you could write a custom CodeActivity to handle more complex logic and run this in your workflow. Running your logic in a workflow will also work if you want to trigger workflows on update of user.

image

Unfortunately, you cannot run workflows on status change of a user nor on update of the status field. If you have logic that should be run when a user is disabled you will have to trigger this manually.

I hope this will help you to get around issues you have in running plugins on create or update of a user in Dynamics 365.