How to design a workflow that cycles through all the items in a list - without calling a web service

  • 2 December 2015
  • 2 replies
  • 3 views

Badge +4

I have a workflow that i need to run on a 50+ item list. The workflow is complete but the only guides that I can find for running it on all the items automatically involve the 'Call Web Service' action which is disabled in our tool box for security reasons. What other options do I have?


2 replies

Badge +4

Hi Mishaal,

You can query a list and return all IDs you want to update into a collection.  This collection of IDs can then be iterated through using a loop and each item updated as required.

My preference would be to use a Site Workflow but this can be created as an item Workflow.

Workflow:

148708_pastedImage_3.png

Query your list:

You can return all items or filter items based on whatever criteria you like.

148456_pastedImage_0.png

Loop through the IDs of the items from your query:

148706_pastedImage_1.png

Update any fields you like within the current item:

Additional actions can be added into the loop as required.

148707_pastedImage_2.png

Thanks,

Barry.

Badge +4

Hi Barry, thanks for this.

I found another rougher solution which still worked. I created an extra boolean column in the list and then set the workflow to activate when an item was updated, then i used the quick edit to update the boolean column. It wasn't ideal but it worked. Your solution is much more elegant. happy.png

Mish

Reply