Workflow on library triggering when another workflow runs

  • 15 November 2019
  • 3 replies
  • 0 views

Badge +1

 

I have the following two workflows;

 

Workflow 1: Is scheduled to automatically run every night at 3pm to automatically update a date column with today's date. This workflow is needed because i have another condidtional column that uses the date to tell me how long until a document is up for renewal.

 

Workflow 2: Workflow two does a few things, but most importantly it sends out an email when a document is updated or added to the sharepoint list.

 

This issue i am having is that every night at 3pm when the SharePoint library updates the date field, it triggers the other workflow and sends out an email for each document in the SharePoint library. I only want Workflow 2 to trigger when a document has been added or modified. I tried terminating workflow 2 by adding an action in for terminating workflow in workflow 1, but that didn't work. Does anyone have any recommendations to fix the workflow so that workflow 1 does not trigger workflow 2? I have added picture of the two workflows. 5568i7066901BDAEADF96.png


3 replies

Badge +12

@Mfaunc1 .....you need to trigger workflow 2 conditionally. Am I correct to assume that the users don't change today's date, correct? If that's the case then here is the approach:

 

Your night workflow changes the date in Today's Date column which means at that point Today's Date (Previous Value) is not same as Today's Date new value.

 

Use that logic as condition to trigger the workflow. Condition will be "Today's Date (Previous Value) is same as Today's Date". So this way when your workflow 1 changes the date, condition is not met when modified and it will not trigger the workflow.

Badge +1
The problem is that this is in a SharePoint 2010 library and you can't do this type of conditional start on a library, right?
Badge +12

@Mfaunc1 .....In document library.....conditional start is not an option when an item is created but you can do conditional start when an item is modified.

 

If you want conditional start when an item is created then you can use Run If action and put your logic inside that. Run If condition will be Created = Modified.

Reply