cancel
Showing results for 
Search instead for 
Did you mean: 

Site Workflow - Document Review Date Approaching Reminders

Workflow Hero
20 38 11.6K

I tried searching for site workflow examples on the forum and I didn't see a tremendous amount, so I thought I would write about a simple site workflow that appears to be requested often.  The workflow needs to remind the document owner when the document review date is three months away (giving them time to review and update the document).

To run through this blog post, ensure you have a document library in your site called "Procedure".  Ensure that this document library has the following columns:

  • Review Date (Date and Time:  Date Only) - mandatory
  • Document Owner (Person or Group) - mandatory

A site workflow does not get created in a list or library, but is accessible though Settings > Nintex Workflow 2013 > Create Site Workflow.  The workflow designer will open ready for you to start developing your site workflow.

The first thing we need to do is calculate the date in three months time (as we will be using this to compare to the review date).  We will need to save the calculated date into a variable.  Create a variable in your workflow of type Date and Time and name as appropriate.  In the example below I have named my variable vDate3MonthsAhead.

Add the "Calculate date" action to the design node on the workflow designer.  Double click to configure as follows:

CalculateDate.PNG

Now we have the date in three months time, we can query our procedures document library for all documents where the review date = our calculated date above.

The results returned from the query list action will need to be stored in a collection type variable, ensure you have one created.  In the example below I have named my collection variable vCollFilteredRecords.

QueryList.PNG

So I now have a collection of item IDs for the procedures that are due for review in three months time (note this collection could be empty).

For each policy returned, I want to email the document owner and inform them that the review date is approaching.  To do this I need to query the item to get some details about the document.

Drag a "For each" action to the canvas and double click to configure. The target collection is the output from the query list (so vCollFilteredRecords in my case) and the Store result in requires a variable to store the item in the collection's ID.  I have created another variable of type List Item ID called vListIDProcedureID:

ForEach.PNG

Inside the For each container I am going to query the list of the current item in the collection to get the properties I require, and store in relevant variables which will need to be created:

QueryList2.PNG

Finally, I will email the document owner for each item to inform them that the review is due in three months:

SendNotification.PNG

The completed workflow looks like this:

WF1.PNG

WF2.PNG

Publish the workflow.

Now, the clever bit.  This workflow needs to be scheduled to run daily, forever.

Settings > Nintex Workflow 2013 > Schedule Site Workflows > Add Schedule

Complete the schedule as follows:

Schedule.PNG

38 Comments
Workflow Hero

Cassy - nice article!  I am doing pretty much the same thing using a site workflow.  I am referencing a library column named "Expired Date" and will send an email 30 days and 10 days before the due date - sent to the "Assigned To" person.  My logic pretty much aligns with yours. Thanks for providing your solution.

Workflow Hero

Nice and simple solution, good post.

Not applicable

Nicely documented, Thank you.  I had a little different scenario,  I wanted to remind users about their Task Assignment at Due Date Minus 2 days.   Since you can only specify a number of days in the Reminder Tab of the Task assignment I had to find a work around.    I used a date calculation action to find the Date I'd like to send the reminder and stored that in a variable (dteReminderDate).  Then I did a Build String Action with the following  fn-Round(fn-DateDiffDays({Common:CurrentDate},{WorkflowVariable:dteReminderDate})) and stored that in a variable txtReminderDays.   Then in the Reminder Tab of my Task assignment I simply used the txtReminderDays in the Days field of the Time between reminders section.

Cheers!

Brad

Workflow Hero

I assume this is not going to work in O365 because there is no option to schedule a workflow ?

Workflow Hero

Hi Jaap. Did you manage to get a solution for O365? I am looking at implementing exactly this but can't seem to with O365.

Workflow Hero

Good day,

My scenario is the following: 

I have a List with Reminder Date and a Due date. I need to send a Task assignment to the Task Owner on the Reminder date and the Task owner has to complete the Assigned task and attach the necessary documents and Update the Reminder date to the Next Year.

I have created the Initial form from a SharePoint List and created the Site workflow but...(this is where is need help please because this is all new to me.)

in my site workflow on the Task Form it does not see my List columns , am i doing this totally wrong? I have followed your document but still clueless. Any suggestions please.

I have a attached my current site workflow Site workflow pic

Workflow Hero

Indeed this wasn't possible in O365, I have used a bit different approach and it's working with a way of working of course. Yesterday I got confirmation that scheduled workflow is added to the Nintex O365 Workflow capabilities. Not sure what it means for my existing solution. You can also have a look for Document retention management in O365, https://technet.microsoft.com/en-us/library/dn790613.aspx never worked with this and not sure if this is practical (maybe overkill)

Workflow Hero

you have to pull the list item properties that you need in the second query list action?

Workflow Hero

‌ Amazing solution - thank you! Totally fixes my problem (and others) of not being able to get a Pause action to work properly. In your email notification you include the Document title from the variable you set up. Do you have any idea how to include a link to the item? I've tried building one out using, but I keep getting hung up because there's no way to get the list URL or the list name to tack onto a site URL.

Workflow Hero

Gah! I figured out a way to get a full usable URL shortly after posting this. You can use a RegX to trim the junk off the end of the Encoded URL. This will leave you with the URL to the list to which you can add DispForm.aspx?ID=<your item ID varable here>

Workflow Hero

Hello

I have downloaded your wf and I seem to get an error message:

what am i missing here?

Workflow Hero

I think it was a problem with the vListIDProcedureID being a variable > List ID instead of text.

When I chosen a different variable set a text, the workflow works now.

I am yet confused what the FOR EACH does ??
Is it supposed to check how many items are about to expire and then send individual email for each??

I had an impression that it would show a list of all potential expire items on one email instead of multiple emails.

Workflow Hero

yes this example sends an email for each item returned.  there are examples on the community of sending one email for all items where I believe they build html with the collection items.  I will have a search and update this thread.

Workflow Hero

Cassy Freeman‌ your blog worked great, but it's only sending out one email alert for one library item! What am I doing wrong? I've detailed my steps here Any help would be appreciated! I'm going round in circles!

Workflow Hero

Hi Darren Floyd

Yes in this scenario the person to notify may be different for each item, so it sends a notification for each one.

the link you have added doesn't work for me...

I am sure there are examples on here where people have built html table with all items returned from the collection and then sent one email with the html table inside the email.

try these:

https://community.nintex.com/message/67243-re-how-do-you-send-one-email-for-multiple-list-items

https://community.nintex.com/community/build-your-own/blog/2017/04/27/send-grouped-notification-base...

https://community.nintex.com/message/55012-re-send-multiple-notifications-in-one-email

https://community.nintex.com/message/18176

https://community.nintex.com/message/45636-re-site-workflow-that-groups-data

Workflow Hero

Hi Cassy

Thanks for the reply. Here's the link again: https://community.nintex.com/thread/18334-date-review-workflow-only-sending-one-alert.

Sorry I may not have been clear. I'm not trying to send multiple emails out for one item. What I need to happen is that the workflow loops through the library items and sends out emails for each item which has a Start Date seven day in the past, if that makes sense?

Workflow Hero

Hi Cassy,

Great work, this is exactly what I need since I do not want to include a timer job in my approval process workflow.

I do have one question: Once I´ve set this up, do I need to add something server side? Even if I create this site workflow and make it run every day, it doesn´t seem to do that on my site.

Best regards,

Workflow Hero

As long as you schedule it - it should be good to go.  feel free to post a new question outlining the issue and link to it here for me (and others) to take a look at.

Workflow Hero

Cassy,

Great workflow got me going in the correct direction and THANKS for that. I have an SharePoint 2010 ECM solution that contains multiple libraries with the same content type. Once documents hit a status they will have a review period. What im wondering is how to query multiple libraries with a site workflow every day and start a another re-approval workflow. I am struggling with how to query across multiple libraries and get the correct items to be acted on by the workflow. Any tips would be greatly appreciated. And thanks for being part of the community!

Workflow Hero

Hey!  glad it was of some help...

I have done this before where I have changed the query list into CAML and used List Title instead of ID.  then have a variable required on start form where I specify the list name for query.  that way I can schedule the same workflow many times but for the different lists I need to query.  does that make sense?

Workflow Hero

So as I understand it you are building multiple iterations of the same workflow each focusing on a separate library?

Workflow Hero

Maybe if I explain in a little more detail. Apologies if this is a long explanation

I have 9 individual factory sub sites, each of them 9 Individual libraries all with the same content type applied to them. My goal is the following

1) All items in these libraries are records and each has an approved date which is the date it was last approved +1 year.

2) I have a calculated column that grabs 90 days prior to approved date. (In effect an expiration date)

3) I need to be able to run a site workflow that queries all 9 individual libraries and find all items that are 90 days prior

4) I then need to change these items status and move those items to a separate library that will start the reapproval process on them.

This solution it around ISO9000 documentation so it has a lot of requirements around retention and access. I am trying to make this process as hands off for the users as possible

Currently based on your previous email I have configured a CAML query that looks like this (Please realize I haven’t setup all my variables and calculations yet)

</Value>

</Leq>

</Where>

</Query>

Any advice is greatly appreciated

Thanks.

Workflow Hero

I am getting this too...

Workflow Hero

Awesome post. Got it to work!  THANK YOU! 

Workflow Hero

yes exactly!

in your original site workflow you used query builder to select the library you wanted to look in.

What I am suggesting is changing your CAML query from this:

<Query>
  <Lists>
    <List ID="{6C4BEE8F-C61F-4127-A75C-6D5617F31F76}" />
  </Lists>

to this:

<Query>
  <Lists>
    <List Title="{WorkflowVariable:vTextListName}" />
  </Lists>

Workflow Hero

Is there a way to do this by grabbing only the most recent date entered if it's older than 14 days?  I have 4 col: Emp, ReviewTopic, Reviewer, and ReviewDate.  I need to send an email to each employee if the last (most recent entered) review date is older than 14 days.  Been racking my brain and these forums for a few days now.  I can get it to email each employee (regardless of the last date entered) or not at all.  Thanks in advance

Workflow Hero

Can you use sort order on query list to make sure most recently modified is at the top. Then look at that date to see if more than 14 days? Have you posted a question relating to this? If so please link it here and I’ll take a look.

Workflow Hero

I did but deleted it and then not even 30 minutes after I posted the reply above I was given some information that fixed the issue.  I will post the wf and the fix in the morning. Thanks for the quick response.  I actually modeled it off of a few posts you made.

Thx

Workflow Hero

The issue I was having ultimately was the person/user account info.  Once I set the user to display name and then used CAML (removing 'LookupId="TRUE"') in my nested query my wf worked perfectly.  Again thank you for your past examples.

Workflow Hero

Are you getting the same error message as seen on my screenshot above?
If do, then do what I suggested:

update the vListIDProcedureID from List ID to Single Line Text.

Workflow Hero

I think at some point I may have done that. I have written several workflows for items coming due and so far all are running ok. My new "issue" is a soap: error.  

Thanks again. 

Workflow Hero

Cassy Freeman‌ 

I've created WF on nintex, the first reminder is working. I defined the To (Owner) and the Owner received the email. But the second reminder Owner not able to receive the email. the 2nd notification I used the site WF to schedule the timing. Any help is much appreciated. Thank you

Workflow Hero

Gel G‌ please can you create a new question on Getting Started‌ with some screenshots and I (or others) can help.

Workflow Hero

How did you do that? I'm trying to include a link to the item but I have not had much luck. I'm creating a site workflow to run every day.

Workflow Hero

What are you trying to link to? I cannot find the post/thread with the question.

Workflow Hero

To display the form you have to add the ....DispForm.aspx?ID= {The item ID variable}

But you have to add it at the end of the path for your list:

https://teams.piedmontng.com/sites/Transmission/Lists/Dew%20Point%20Meter/AllItems.aspx

https://teams.piedmontng.com/sites/Transmission/Lists/Dew%20Point%20Meter/DispForm.aspx?ID=I normally add that pat in the body of the email using the INSERT Link option. The address with the DispForm address goes in the address section. I normally create an ID variable if I am creating a site workflow. This is the variable goes after the =.

Workflow Hero

This site workflow solves so many issues.  Thank you very much for all of the detail included.