Step-By-Step Running On-demand Workflow For All Active Records

Have you goten a requirement to run your workflow for all active records? If yes then this article will help you to implement it. OOB in Microsoft CRM web client we can run our on-demand workflow only for 250 records, but there are some workarounds to overcome this limitation, for example we can use the Microsoft CRM Outlook client, because in the Outlook client there is no limitation on the number of records per page. If you are using the Outlook client for Microsoft CRM and are interested in this workaround then check this.

But if you are not using the Outlook client for CRM then you can use Workflow Execution Manager from MSCRM ToolKit. In this article we will provide step-by-step instructions of how to use this tool.

So for implementing this requirement we need to use the following procedure:

  • Create an on- demand workflow for your requirements.
  • Get FetchXML query for your entity records.
  • Configure Workflow Execution Manager to run your workflow.

Create an on- demand workflow

Let’s create our on-demand workflow, in our example we are creating a workflow on ab account entity to set the custom category as standard. So navigate to "Settings" -> "Process" -> "New" and fill in the following details:

Process Name:
Entity: Account
Category: Workflow

Click "Ok" and add an update step to set the account category as “Standard” (click on the Set Properties button to set the account record category) . Save and Activate the workflow. After completion our workflow should look as in the following.

accountowkflow

Get FetchXML

Now navigate to Advanced find and design your query and click on "Download Fetch XML" to get a fetchxml query.

advance find

Configure Workflow Execution Manager

Download Microsoft CRM Toolkit from Codeplex and extract it. Click on MSCRMToolKit.exe to start and use the following procedure.

Select "Connection Manager" and fill in the following details:

workfloeexutt

Test your connection and close the connection manager dialog.

Start the Workflow Execution Manger from the Tools menu and use the following procedure.

Profile: Provide any name.
Source: Select your connection name.

Click on the "(Re) Load Workflow" button to load your all on-demand workflows. Paste your query into the Records Query text field and save your profile from the File menu. It should look as in the following



Click on "Execute Workflow", it will start your workflow and will process all resultsets based on the query provided.


Similar Articles
HIMBAP
We are expert in Microsoft Power Platform.