cancel
Showing results for 
Search instead for 
Did you mean: 

Scheduled Workflows in Office 365

patrick_hosch
Nintex Newbie
17 22 10.8K

Updated: Aug. 2, 2017 

Please note that Scheduled workflows feature has been released as of July 2017. Please see  for more details on this fix.

As many of you are aware our product teams are working hard in extending the capabilities of Nintex Workflow for Office 365. Some features might currently be missing but will certainly make it to the product soon. In the meanwhile, most of the features you might miss can still be implemented, simply by thinking a bit outside the box.


One of these features is scheduled workflows. In this post I will show you how you can use existing workflow actions, SharePoint features and quite simple logic to allow workflows to run on a schedule power users can easily maintain themselves.

What do we need?

I provided the templates for the following as part of this post. Feel free to download and use them.

A SharePoint List

The list will contain one item per workflow you want to schedule. Each item will represent one scheduled workflow and consist of the following columns:

    • Workflow Title - The name of the scheduled workflow;
    • Schedule Frequency - Specifies the time in-between workflow runs. This is the number of minutes. That can also be changed to hours or days if you need to, by simply changing the corresponding workflow action.
    • Schedule End Date - Sometimes you want to run a scheduled workflow only to a certain date. Note that the workflow will run at least once on the specified date. This field is optional.

The Workflow

The provided workflow template can be used as a base for each scheduled workflow you want to create. This is the minimum functionality required to mimic a scheduled workflow. What happens in the workflow? Lets dissect the following screenshot:

Scheduled Workflow.jpg

    • Loop until Schedule End Date - This is using the Loop with Condition action which will continue to loop until today's date reaches the specified Schedule End Date which is part of each element's metadata.
    • Set dateToday to today's date - This sets a variable, called dateToday, to today's date
    • Pause for specified frequency - This uses the Pause for Duration action to pause the workflow for the number of minutes specified in the item's metadata
    • The red rectangle - This is where your actual workflow logic goes. The rest has to stay as is, but this is where you build the logic for your scheduled workflow.

How do I schedule the workflow now?

To get started, create a list based on the list template in the .zip archive.

Next you need to build your scheduled workflow within the Scheduled Workflow list. For that use the provided workflow template. Set it to a manual start as you only want it to start once the schedule is in place.

After publishing the workflow, go to the list and create an item. Provide details as required and then manually start your workflow on that one list item. The workflow will then run on this item on the specified schedule.

Obviously this is a sequential workflow, but the logic will also work in a state machine. When I have more time, I will provide a template for that too.


Feel free to provide feedback and comment on the approach. Hope this helps everyone who needs scheduled workflows in the interim.

22 Comments
Not applicable

Hi Patrick,

I know this is an old post, but I have a couple of questions:

  • I haven't found any updated information about Scheduled Workflows in Office 365, so I guess this post is still valid?
  • When running the workflow like this, will the workflow continue to run, if the account that started it, gets disabled or deleted?
Not applicable

Hi, Anders Lund​!

If you post your question in the Learn More​ area of the site, it's more likely to be seen and answered by community members.

Thanks and good luck!

Frank

Not applicable

I've taken an different approach by offloading the scheduling to an Azure WebJob, which calls my workflow. I think it's more resilient, as WebJobs are purpose built for scheduled task running. I wrote up my thoughts and instructions in this post: Scheduling workflows in SharePoint Online with Azure WebJobs

Not applicable

Hi,

I have used this workflow but instead of the pause control I am using a "wait for" control. This allows my scheduled actions to run continuously without worrying about workflows overlapping if frequencies are not long enough, as the result of this would be a "Suspended" workflow. My question is, if I have this scheduled workflow running continuously on hundreds (not thousands) of items should I expect performance issues or any other issues?

Thanks.

Not applicable

It would make me nervous. Would you have an instance of each workflow running on each item?

It should work in theory, but my experience with Workflow for O365 has been that things simply fall over for miscellaneous reasons with too high a frequency, for me to trust things that should technically work. If you had 100+ instances of this workflow running that is creating 100+ points of failure that would be difficult to monitor.

courtney_shelto
Nintex Newbie

Hey Sunny,

I read your blogpost, but I was wondering, how would you go about setting up an Azure webjob that would run a *site* workflow? I have a site workflow created in Nintex for O365 that I need to run daily. The site workflow runs against a list and checks for when the "Next Review Date" == "Today" (today is created using a workflow variable that sets todaysDate to "date when action is executed"). I don't want to use a "pause until" or "wait for" in a list workflow as the "Next Review Date" can change and a suspended workflow would not "see" or recognize that.

Warwick
Nintex Newbie

Seriously just purchase this app from the app store at $150 per year. Why Nintex have been "trying" for nearly 3 years to build this now and they haven't just acquired this company, I just don't know....

Plumsail Workflow Scheduler

Get on it, and get it done rather than dealing with this convoluted solution (though still creative, I have to give it credit for that)

courtney_shelto
Nintex Newbie

I was looking at that app actually! Couldn't find much on it in terms of reviews though and security (our Information Security guy is gonna want info). Have you been using it? Has it been resilient and reliable?

greenawayr
Nintex Newbie

Terribly disappointing that this has not been resolved yet. It's pretty much a core reason for using Site Workflows. ‌, can you imagine migrating to O365 and not being able to use a scheduled site workflow?

Chris_Ben
Nintex Newbie

Here's the link to the UserVoice suggestion.  It was updated last week to say investigation has begun.  However, I'd suggest people still vote on UserVoice to give it more prominence.

Cheers,

Chris

patrickabel
Nintex Newbie

Ryan GreenawayChris Ben‌ I just built a site workflow for a client (Nintex for Office 365) specifically because I knew that I would need scheduling capability. It is indeed disappointing to find this feature is not available in Nintex for O365.

I would say this is the most frustrating aspect of Nintex development – inconsistency between platforms.

It's easy to getting accustomed to best-practices or how best to accomplish different things and then you run up against a wall because of lack of support or differences between each version of the product.

greenawayr
Nintex Newbie

Totally. As a consultant who is with his first o365 client I totally get this. This is why I have been asking for some sort of consultants license, not for me to do anything productive with, but for me to be able to fully understand the platform ahead of time and be able to advocate Nintex to clients knowing the limitations and possibilities ahead of time.

Warwick
Nintex Newbie

Yeah I have to sympathise with you there, selling a client on workflows in Office 365 based on what they/you know of in on-premises must be tough without quite a bit of experience in the new platform, as they are very different  and not just in straight feature comparison.

greenawayr
Nintex Newbie

Thanks to this place, I actually learnt ahead of time to not use the words "yeah, you can do that on O365 with Nintex".

TomaszPoszytek
Nintex Newbie

I still stand in position, that having right tech background you can achieve anything

Like you can sometimes use azure, to host there services available using , and call them when needed from you Nintex Workflow 

Regards,

Tomasz

greenawayr
Nintex Newbie

I'm a consultant, when I leave the solution I provide them needs to be supportable by their IT team and skillset they have to hand. In the limited time I have here, I can train them on using Nintex and the OOTB functionality it provides. I can't train them on  web services and programming languages. It's needs must.

patrickabel
Nintex Newbie

Unfortunately as Ryan Greenaway mentioned "achieve anything" isn't always the goal. Oftentimes success is defined primarily by user-adoption and by empowering citizen developers (less technical individuals) to be able to develop and maintain their own solutions – click not code.

Although I spend a lot of time in azure and client-side development, those are a last resort when it comes to Nintex for me. If not, you reach a situation where a client wonders why they purchased Nintex in the first place if custom development was required for their specific needs.

courtney_shelto
Nintex Newbie

While it's not a perfect solution, as mentioned earlier in this thread, Plumsail is an inexpensive, "click not code," easy implementation for users. Of course, it would be preferable for it to all be in Nintex, but there are other solutions that fit your needs for less technical users. And at $150/yr, it's a drop in the bucket for most orgs, especially if they're already purchasing Nintex and someone to implement it.

patrickabel
Nintex Newbie

Very true Courtney Vargo! In this situation, there's a lot of solid options.  

Chris_Ben
Nintex Newbie

I note that KK wrote a very detailed post a couple of days ago on how to achieve this using NWC as NWC has scheduling capabilities.  His solution falls in the advanced camp right now but when more of the o365 actions for NWC are released, I feel it will become much easier.

Cheers,

Chris

greenawayr
Nintex Newbie

Thankfully it seems Nintex Dev Ops are on the case.

Schedule Site Workflow – Customer Feedback for Nintex 

hardyj
Nintex Newbie

Hi All,

Please note that Scheduled workflows feature has been released, so the workarounds are no longer required. Please see the blog about it here: https://community.nintex.com/blogs/NintexProductBlog/2017/07/24/teeing-up-your-work-scheduled-workfl... 

scheduled workflow‌scheduled workflows‌