Categories
Office 365 SharePoint Workflows

How to do Workflows in SharePoint: Part 3 – Scheduling a Workflow

This is part 3 in a blog series of basic workflow design using SharePoint Designer and Microsoft Flow. See How to do Workflows in SharePoint: Part 2 – Parallel Actions for the previous entry in this series.

Sometimes its necessary to run a workflow on a continual basis. For example, to check for updates or changes to items in a library, or to do a monthly tally of list items with conditional statuses.

SharePoint Designer

Unfortunately there is no “silver bullet” easy answer to do this – kind of like if a video game only had a hard setting. In SPD there is no overt trigger action or condition for a scheduling scenario. However, crafting a workflow is definitely possible, and it depends on your use cases and objectives for your business process.

Let’s say you want create a workflow that runs every day at 2:00 A.M. (starting tomorrow). The workflow will update a title with a new value .

  1. Create a SharePoint 2013 workflow on the library or list.
  2. Insert a Stage to kick-start the workflow at 2:00 A.M. (use the Pause Until action).
  3. Insert a Stage called “Field Update”, and have a variable continually update with every loop (e.g. variable +1). Then have the Title set to this variable value.
  4. Insert a Stage at the end of the workflow and call it “Timed Loop” or something similar (it’s best practice to name your workflow stages with descriptive titles as accurately as possible).
  5. Insert a Pause for Duration action and have it set to 24 hours.
An example of a scheduled workflow using SharePoint Designer. Thank the heavens for Stage management, otherwise this would be a dozy!

This is a simple example of how one could have a scheduled workflow built with SharePoint Designer. However, it’s not a silver bullet. This workflow needs to be started manually (once), and it will also never technically “end” as it keeps looping for infinity (Loop steps can be used if it only need to loop X number of times, or given certain conditions). I like to think of this as a proverbial MacGyver job, and really only used if SPD is either required or your workflow jam.

Microsoft Flow

Comparatively speaking, building schedule jobs in Microsoft Flow is like taking a warp zone to the end of the game. It’s fantastically easy.

  1. After creating a new Flow, chose the Recurrence trigger as the first item. Set up the recurrence interval, and set the Start time (you’ll have to know the format for your start time, which could be a bit easier, but c’est la vie).
  2. Attach your normal workflow steps.
Use the Recurrence trigger to set a scheduled Flow. Much easier!

Which one is easier: No doubt Microsoft Flow is easier to use for scheduling actions on SharePoint lists. However, there are third-party options for workflows that make the setup of scheduled workflows much easier, such as Nintex Workflows or even work it in with Windows Task Scheduler. But without investing in third-party applications, Microsoft Flow is the clear winner. Happy Scheduled Flowing!

Please visit my blog Ion All the Things for helpful information about SharePoint and Office 365!

Categories
Microsoft Teams Office 365 SharePoint

Where are my features!?!

Microsoft has done a really great job over the last 6 months to bring to light all the hard work they are doing within SharePoint Online and Microsoft Teams. Between the announcements at ignite , various blog posts, twitter users like @anne_michels and @vesajuvonen. There are a ton and I mean a ton of new features coming to teams and SharePoint that we have been asking for since modern sites and teams came into existence.

Now the question is… When are we getting these features? Microsoft has provided a very handy tool called the Microsoft 365 roadmap. You can find it at https://www.microsoft.com/en-us/microsoft-365/. This site will provide you with an overview of the high-level new features the Microsoft is developing and rolling out to Windows 10, Office 365 and EMS.

If you want to see just SharePoint Online and Microsoft team roadmap you are able to filter your results to return only those. https://www.microsoft.com/en-us/microsoft-365/roadmap?filters=Microsoft%20Teams%2CSharePoint. This may sound great however how accurate is the roadmap?

Well judging by the top few results for SharePoint.. Not very accurate. According to the roadmap organizational news was released last month and yet is still in development.

What I have noticed is the release date is when Microsoft will start rolling out the feature to tenants that are set up for targeted releases. Even if you are setup for targeted releases you may still be waiting weeks for the feature to make it to your tenant. If you are on the standard release it will be weeks and possibly months before you get it.

Currently there is no way for you to know when the anything will be released to your tenant. So be wary of what you read and try to stem the excitement and set realistic expectations with your business or clients to when they might be able to start implementing these amazing new features.

Categories
Devops SharePoint

Mike’s 2019 Predictions

With 2018 over and 2019 just beginning I thought it would be fun to make a few guesses as to what I think will happen around the technologies that I work with on a daily basis.

Predictions

  • SharePoint Online Intranet projects move from boxed solutions back to OOTB then back to boxed
  • SPFX will play a larger role in a SharePoint Developers toolbox.
  • Serverless architectures will move from trial, curiosity and POCs to mainstream first class architectures

Intranet Projects

Currently there are a variety of different boxed solutions for corporate intranets. Examples would be GO, Bonzai, and Sparrow. These are all great solutions to get your intranet done quicker and lower the development time to create an engaging intranet.

The downside is that you are tied to a specific vendor. Locked in for a support contract with no real options to move if you are unhappy with them for what ever reason. These intranets are based off of classic publishing sites templates. While not necessarily bad, Microsoft is just not investing in this space anymore.

Microsoft has rearchitected the way SharePoint sites work. With the release of Hub, Modern Team and Communication sites and with the most recent updates to these site templates. I feel most organizations can finally start to build OOTB Intranets that look custom, look on brand, and are relevant to the users consuming the content.

While the makers of Go, Bonzai, Sparrow and others figure out their best path forward on how to create useful products in this new world. Organizations will start to leverage these new updates in their intranets as first step instead of as an addon.

SPFX — SharePoint Framework

The SharePoint Framework is a client-side development toolkit that allows you to build Webparts and extenstions for SharePoint Online, SharePoint 2016 with FP2 and SharePoint 2019 and most recently Teams.

The ability to write a solution once and have it work in any modern SharePoint environment and Teams is huge win for developers and the money counters. SPFX being entirely TS or JS based fits quite nicely into organizations DevOps strategies.

SPFX is the best way to write web parts for modern SharePoint sites.

Serverless Architectures

As SharePoint developers adopt SPFX as their main way to create web parts for SharePoint and teams. Some functionality will be lost. The ability to run server side code. This is where I think serverless architectures will start to take off more.

Since SPFX is entirely client side facing developers will need a solution to deploy and client side code that they may need. The answer for this in the Azure world will be Functions and Logic Apps. In the amazon world it will be Lambda.

The idea being that instead of creating an entire infrastructure to host what is most likely a small piece of logic. We have these serverless architectures where our logic is hosted and called only when it is needed. Saves a lot of time and money.

Categories
Office 365 SharePoint Workflows

How to do Workflows in SharePoint: Part 2 – Parallel Actions

This is part 2 in a blog series of basic workflow design using SharePoint Designer and Microsoft Flow. See How to do Workflows in SharePoint: Part 1 – Conditional Starts for the first entry in this series.

Sometimes you want a workflow to do more than one thing at the same time. It is not an uncommon business case to require simultaneous activities, especially if the workflow needs to do different things with different groups of people (e.g. getting separate streams of approvals between Supply Chain and HR). 

SharePoint Designer (SPD) and Microsoft Flow will always conduct workflow steps in sequence. If you require that certain things get done simultaneously, both applications can provide the controls to do it.

SharePoint Designer 

Use a SharePoint 2013 workflow on the library or list. Parallel blocks are not available for SharePoint 2010 workflows.

  1. Insert a Parallel Block (inside a Stage). You can do this from the Insert section of the Ribbon (or by right-clicking).
  2. Write the logic you need in each block (there is a slight indent into the parallel actions).
  3. That’s it! Consider using Steps inside Parallel Blocks to organize your parallel actions into manageable blocks (and to see your actions visually separated from one another!)

Nested Parallel Blocks (Waiting for one of multiple things to happen)

Parallel Blocks can also be used for Conditional Starts in waiting for a field to change in order to proceed a workflow. This is handy if you want to wait for certain values in a field before doing the next step (e.g. approval statuses).

  1. Add a Parallel Block to your workflow.
  2. Add as many nested Parallel Blocks inside the parent Parallel Block as you need.
  3. For the parent Parallel Block, right-click on it and click Advanced Properties.
  4. Set the “CompletionCondition” to a new boolean variable. By default, the new variable will continue further if the variable equals “true”.
  5. In each nested Parallel Block, add a “Set Variable” status so that the new variable equals true.
  6. That’s it!

What you will get is the workflow “waiting” for one of the nested Parallel Blocks to be true before proceeding. This is very handy if only certain conditions have to be met, and not working within the limitations of the operators provided (e.g. equals, not equals).

Microsoft Flow

On a workflow that already has a trigger and an action, hover your mouse about the connector line and click the + button. You can add a parallel branch. When the new parallel branch is created, it will be create adjacent to the main workflow stream. Add all of the actions you need within this branch. When you want the parallel actions to end, just at a new step at the after both branches are complete (it will auto-join).

  1. On a workflow that already has a trigger and an action, hover your mouse about the connector line and click the + button. You can add a parallel branch (1).
  2. When the new parallel branch is created, it will be create the new branch adjacent to the first workflow stream. Add all of the actions you need within this branch in sequence as required (2).
  3. When you want the parallel actions to end, just add a New Step. It will conjoin the two (or multiple parallel blocks) together (3). This is not the same thing as “adding a step” under a current Parallel branch; two different function!

Which one is easier? Microsoft Flow, for the simple fact that it is visually easier to look at when doing branch design (this just doesn’t look as appealing in text-based logic, but to each their own). Of course with that said, you can always view and edit your workflow in Visio (click the View button and pick “Visual Designer”).

In the next entry in this series, we look at basic steps to scheduling workflows (a bit more advanced, depending on which tool you are using!).

Please visit my blog Ion All the Things for helpful information about SharePoint and Office 365.

Categories
Office 365 SharePoint Workflows

How to do Workflows in SharePoint: Part 1 – Conditional Starts

Workflows are the lifeblood of organizations. Business processes – and their efficacy – are critical to the successful operation of a team, business or organization. This is why the workflows you use in your collaboration tools should be easy to build, deploy, and use by people of various responsibilities and technical chops. SharePoint workflows should follow suit.

In the first of this three-part series, I will address some common scenarios you may need build into your SharePoint workflow and how to go about building what you need in both SharePoint Designer (still kickin’) and Microsoft Flow (the shiny new object and getting shinier!) Below are simple ways to begin your workflows that need have conditional starts, where certain conditions must be met on a document or item before the workflow can proceed.

SharePoint Designer

  1. Create a new SharePoint 2013 workflow on your library or list.
  2. Set how the workflow starts (created, modified, manually) in the options menu.
  3. In the Logic screen, insert an “If” statement in the first stage. Add another “If” statement right below it to create multiple conditions (something not so obvious in SPD unfortunately). This is where you can select your operator (“and” or “or”).
  4. Pick the fields and pick the values it must meet conditionally.
  5. Complete the If/Then logic you require. Don’t forget to use an “Else” statement to tell SharePoint what to do if the “If” statement isn’t realized, otherwise it will continue to follow through in chronological order. It is also good practice to include a “Log a Message to the Workflow History List” so that any audits done on the workflow for a given list item can be reviewed with more context and see how the workflow followed the logic.
A basic workflows in SharePoint Designer with a conditional start.

Microsoft Flow

  1. Start a new workflow (either from a template or from scratch).
  2. Create a Trigger. Your trigger should be how you want the workflow to begin (on item or document creation, modified, manually, for a selected item, etc.)
  3. Create a Condition action (use Basic mode for one condition, and Advanced Mode or parallel or nested conditions for more conditions).
  4. Add your subsequent workflow steps in sequence.

A basic workflow in Microsoft Flow with conditional start.

Which one is easier? I feelSharePoint Designer is easier on the whole, especially for starts that require multiple conditions (you don’t have to write logic in Advanced Mode or do nested conditions). However, the graphical user interface may be more appealing to some workflow builders. Try both and see what you like!

Next in the series is how to handle Parallel Actions (having more than one action run simultaneously).

Please visit my blog Ion All the Things for helpful information about SharePoint and Office 365!