Skip to main content

Using SCRIBE Online For Scheduled Tasks

While doing client work, I ran into a need where we needed to scan for records where a date value is 3 months in the future (i.e. 3 months from today) in Microsoft Dynamics 365.  There are a few options to accomplish this:
  1. Microsoft Dynamics 365 SDK (Developer Guide)
  2. Timed workflows
  3. SCRIBE Online
The issue with using the Microsoft Dynamics 365 SDK (Developer Guide) is you need a software developer to create a console application that is linked to a Windows scheduled task to run every night to connect to CRM, query the records and make the changes.  This means if you need any updates to the application you need to developer to change source code.  This is a viable option if you have an internal development team that can support the application.

When it comes to using timed workflows with wait statements, we would need to have the workflow fire at a specific time in the record.  In this scenario, this means that the workflow needs to fire to start the countdown (wait) when the record was created or when the date field we are monitoring changes.  The problem with this is the more waiting workflows you have in the system, you will start to see a degradation in performance.  Also, if someone manually changes the date field you will need to find the previously waiting workflow to stop it as you will have duplicate workflows waiting.  This can be a nightmare to manage.

The solution that we came up with for this client was to use SCRIBE Online to perform these actions.  Typically, when we think of SCRIBE Online, we think about connecting 2 systems, replicating data to another database or migrating data from one system to another.  There is more that we can do with it and this is one of the areas.  In this scenario, we have an integration map that is setup with only 1 connection as both the target and the source (Microsoft Dynamics 365).  We set the solution containing the mapping to run nightly and query for any records where the date field on the record is 3 months from the date the mapping is running.  If it is true, then it generates a record that will kick off a record creation in CRM (Triggering Entity) that will kick off a workflow to generate a bunch of related records to the account this the date field.

With the above setup, there is no need for a developer to update code as the process can be updated with the internal CRM workflow and SCRIBE Online, which both use an easy to understand GUI.  By moving the counter outside of CRM, we also make sure that the CRM system won't lose performance.

The main reason for my blog post about this, is to show that we can use SCRIBE Online for more than just data migration, integration and replication.  The more that I work within SCRIBE Online, the more I can see its use for other tasks.


  1. Depending on the legacy database and the connection source, what do you think about creating another table with just the date ranges you need and put a Where clause in your original query using SSIS? If you need to update the range then edit the table.


Post a Comment

Popular posts from this blog

Dynamics 365 v9 Unit Testing and .NET Confusion

Recently while creating a plugin for Dynamics 365 v9, I ran into an issue trying to connect to CRM via the tooling connector in my unit test project.  The underlying problem was that the .NET version I was using in my unit test was 4.5.2.  This was preventing me from being able to connect to CRM to create my organization service.  I updated the .NET version on my unit test project to 4.6.1 and was then finally able to connect.  I will also add that I am using the latest nuget package version for Dynamics 365 v9.

For consistence, I updated the plugin project I was working on to .NET 4.6.1.  Locally, everything was working great.  I was able to connect to CRM and make sure that all the methods I had written did what they where suppose to do using test driven development practices.

Then when publishing my plugin via the latest version of the plugin registration tool, I received an error and could not publish my plugin.  The error was due to the .NET version of my plugin project not bein…

Getting Started Connector Development

One of the benefits of working with Scribe Online is how easy they make it to create connectors if one does not exist.  In this blog post we are going to look at how to get setup, if this is the first time you have made a connector for Scribe Online.  But, before we get into that, we should first make sure that a connector doesn't already exist that can handle what we need.

We can do this by looking in the Scribe Online Marketplace.  Still not seeing what you need?  Reach out to Scribe directly or ask in the Scribe forums if a connector exists for an application.  There are instances where a connector exists but is not listed in the marketplace.  An example of this is for a client that I built a connector for.  They didn't want to setup a system to run the on-premise agent, so they asked me to set up the connector to run on Scribe's cloud agent.  This meant that I had to submit the connector to Scribe for validation.  Once published the connector is in the Scribe marketpla…

XrmToolBox Bulk Attachment Manager - Version 2018.2.2.7 Released!

Today I have published version 2018.2.2.7 of my XrmToolBox plugin.  The purpose of this plugin is to make it easy to download and backup attachments in CRM.  This release is a major release as it is the first built version with all pieces working.  The first version only had note downloads working.

Overview of Plugin:
Current Version: 2018.2.2.7Purpose: Download Attachments and E-Mail attachmentsGitHub Link.GitHub Wiki Link.Nuget Package Link.How To Use The Tool: Launch XRMToolBox.Connect to organization.Step 1, choose what you want to download. (Once a choice is made, Step 2 becomes usable)Notes - Download attachments from note entity.E-Mail - Download attachments from emails.Both - Downloads attachments from notes and emails entities.Step 2, choose if you want to download all attachments in the system or specific attachments.  All Attachments - This will search the chosen entity to find all records that have an attachment and download them.Click on "Browse" and choose where t…