Looking for PowerObjects? Don’t worry, you’re in the right place! We’ve been part of HCL for several years, and we’ve now taken the final step in our acquisition journey: moving our website to the HCL domain. Nothing else is changing – we are still fanatically focused on Microsoft Business Applications!

PowerObjects Blog 

for Microsoft Business Applications


Setting Up Recurring Workflows in Dynamics CRM 2016

Post Author: Joe D365 |

Dynamics CRM 2016 doesn't quite yet have the out-of-box ability to schedule workflows to run regularly like weekly, monthly, yearly, etc. However, there is a work-around you can use that utilizes the CRM workflow "wait" step and child workflows to achieve this functionality. Let's walk through the steps for configuring this!

1. First, define the logic for how the workflow should be triggered the first time it needs to be executed. This can be either when the action is created or as an on-demand workflow, whichever is applicable for the business requirement in question.

We do not want it to run on other events such as update or status changes as they can cause the workflow to be triggered multiple times. The best option is to make it on-demand to limit the number of recurring workflows and the performance impact that comes with it. We also want to set the process to: As a child process.

recurring workflows

2. Define the logic of the action that needs to be executed every time the workflow runs like sending an email, creating a task or phone-call to follow-up, etc.

recurring workflows

3. Add the wait condition to the frequency needed as the last step of the Workflow.

recurring workflows

recurring workflows

4. Create another workflow and check As a child process.

recurring workflows

5. The only step left for this workflow is to call the main workflow. We have to do this step since the workflow cannot call itself in CRM 2016.

recurring workflows

6. Now, call the child workflow from the main workflow after the wait condition.

recurring workflows

This process will make sure the workflow is triggered initially according to the condition (create of the record, update of the field/status) and set the recurring workflow jobs in action. If you want to stop the workflow after certain conditions are met, you can specify those conditions in the child workflow as a check condition before looping back to the original process.

Note: Wait conditions on workflows will require resources and may cause performance issues if there are too many running at the same time. Consider making them on-demand or adding check conditions in the child workflow to end the frequency if they do not need to run all the time.

That's all for the blog today! Check out our Dynamics CRM 2016 Update Webinar Series to keep updated on all the latest and greatest with CRM 2016.

Happy CRM'ing!

Joe CRM
By Joe D365
Joe D365 is a Microsoft Dynamics 365 superhero who runs on pure Dynamics adrenaline. As the face of PowerObjects, Joe D365’s mission is to reveal innovative ways to use Dynamics 365 and bring the application to more businesses and organizations around the world.

9 comments on “Setting Up Recurring Workflows in Dynamics CRM 2016”

  1. I did a similar solution form crm 2016 online by creating two workflows and once the 1st workflow is done it calls the 2nd workflow which later on called 1st workflow. It worked fine for around 8 executions but later on the workflows were stopped by the system with the following error :

    This workflow job was canceled because the workflow that started it included an infinite loop. Correct the workflow logic and try again. For information about workflow logic, see Help.

    Any idea on this ?

    1. Yes, this will eventually happen when using workflows which trigger each other. This solution is therefore inherently flawed, the only alternative would be to create a script/console app to initiate an new on-demand workflow on a schedule.

    2. There is a limit of 7 executions per hour (even the child workflows count I think) . If there are more executions the platform triggers an infinite loop exception. So you just need to be careful how often you trigger the workflow. Another thing you have to be aware of is a 2 min. limit of execution time for workflow. So if you have some lenghty operations in your workflow action, you should include an Input Parameter with record count or even better time your execution and exit before it surpasses the 2 min limit.

  2. It's work very well.
    The only problem is: when I create a new account the workflow starts! So the time out is not respected!

  3. It's work very well.
    The only problem is: when I create a new account the workflow starts! So the time out is not respected!

  4. It's work very well.
    The only problem is: when I create a new account the workflow starts! So the time out is not respected!

  5. This might work in the past but on latest CRM 2016 Update 2 it fails over with "This workflow job was canceled because the workflow that started it included an infinite loop. Correct the workflow logic and try again. For information about workflow logic, see Help" and the process stop.", I guess Microsoft is getting smarter detecting infinite loops in workflows, as even if you create a child workflow to run parent again it detects it.

    Having said this, if you keep frequency less than 7 runs per hour as mentioned below, this works without issues.

PowerObjects Recommends