Starting Workflows based on SharePoint Events on a Document Set (DocSet)

  • 16 February 2021
  • 0 replies
  • 61 views

Userlevel 5
Badge +20
 

Starting Workflows based on SharePoint Events on a Document Set (DocSet)

kbt142082

PRODUCT
K2 Cloud
K2 Five
K2 blackpearl
TAGS
K2 Process Designer
Microsoft SharePoint
Workflow Designer
Integration
SharePoint
Workflow
This article was created in response to a support issue logged with K2. The content may include typographical errors and may be revised at any time without notice. This article is not considered official documentation for K2 software and is provided "as is" with no warranties.

Issue

1) Starting a workflow based on itemAdded event on a SharePoint document library adding a document Set doesnt start the workflow. (Not the docs inside but the docset itself)

 

2) Starting a worklflow based on ItemAdded and ItemUpdated for documents in a Document Set starts mutiple workflows.

Symptoms

1) It does not start the workflow or 

2) Multiple workflows start.

Resolution

1) K2 does not support workflow start events on folders or DocSets. The Remote Event Receiver has to process the ItemReference to start the K2 Workflow. To do this GetDocumentByID is called to get the details for the item Ref. Folders and docSets have file objects and it will therefore not start the workflow.

 

2) You cannot use both the ItemAdded and ItemUpdated events to start a workflow where documents are added to a DocSet. This will start a workflow for each event registered. This is caused by the way Sharepoint adds documents to the DocSet. First it uploads triggering the ItemAdded Event and then it updates the Document Metadata which triggers the ItemUpdated Event.


0 replies

Be the first to reply!

Reply