1
votes

I need to schedule the import/ export of contacts in Microsoft CRM 2011 (online and on premises).

I plan to create a custom entity to store the scheduled tasks, and a form to set them up (similar to Windows Task Scheduler).

I am not sure how can I actually execute the scheduled tasks. Does CRM 2011 have a service or API I could use to schedule tasks? The solution must work in CRM 2011 online and on premises. Thank you so much.

2

2 Answers

3
votes

Directly from a former Microsoft product team member (Gonzalo Ruiz),

there is no Out-of-the-Box scheduling engine in CRM.[1]

So the answer is no. I recently asked a similar question, and for several reasons, our team decided the best way to go was solution 1: an external task manager (Windows has a few native solutions for this), which would work for both on-premise and online versions. Drawback: you should probably have a reliable server-type machine that you could host the task manager on.

As linked, you can use solution 2, recurring workflows, to achieve a similar result, but there are some drawbacks to this route as well, some of which are mentioned in Gonzalo's blog.

2
votes

As Peter mentioned use of recurring workflows can help here. Setting up a workflow as a child workflow which calls itself after a suitable timeout can create the required conditions.

You can potentially have a configuration entity within CRM which stores the "time to next run" and the workflow can be triggered to run on update of this attribute (this can be useful if the scheduling period is likely to be non-linear). If the timescales are linear then you can just implement the required timescales in the workflow or have the workflow can update the aforementioned attribute before completion so that the child invocation waits for the appropriate time period.