I had a recent request from a client to create a workflow that would only create approval task in the order that the approvers were listed. This allows the approval tasks to be created one at a time rather than all at once, and if a single approver breaks the chain, we can either break the workflow or escalate a change.
While this can be done in custom code or closely in SharePoint Designer, Nintex 2013 allows power users and power admins to create powerful workflows through the browser. This allows for changes and deployment of workflows to occur without the need for solution deployments.
Create a Regular Expression
In order to create the Foreach loop, we need to populate a variable of type Collection with the users that will be approving the workflow. For users populated from the SharePoint People Picker field, use a semi-colon “;” as your split pattern. For the input text, use the “Insert Reference” to apply the column containing the Approvers to the Input Text.
For each Loop
Now that we have the Regular Expression which creates the collection which can be parsed by the loop. We use the userCollection as the target collection which stores the individual user that is the current approve of the workflow process.