Skip to main content

Hi Cassy Freeman. I was reading your post Site Workflow - Document Review Date Approaching Reminders and it closely resembles the workflow I need to build. I have a Nintex form that collects project related information in a list. I need to loop through this project list each month, locate those projects that have project create dates of greater than 100 days, and send an email reminder to the project owner to update the project status.

Your post is related to a site workflow and so didn't know how to best build with a List workflow. Is it the same or similar?

Thanks.

Hi Jeremy

List workflows is used when something triggered on a list item, since your requirement is to loop thru all projects in the list every month and send a notification as per business requirement, you should use a "Site Workflow" and schedule it to run for every month.

Thanks,

Krishna.


So I built the site workflow based on the similar steps from Cassy's post and the workflow runs, but it does not generate the email notification from the parameters I need the workflow to run on. Those are: projects that are older than 365 days and those that have a Project Status <> Completed. Here is what I have so far:

Something or somethings are not connecting and providing the emails that will need generated for review.

Any thoughts?


I see below issues as per your screen shot:

1. In "Query List" action that is after "Calculate Date", you have not selected ID field, but selected "Created" in itemIDCollection variable.

2. In "Query List" action that is in "For Each", apply filter on "ID"  equal to "currentitemID" (from For Each action)

Hope this works after the above modifications.

Thanks,

Krishna.


Awesome. Thanks for the feedback. Just one clarification. For the "Query list" action that is after "Calculation Date"...are you suggesting I should replace "Created" with "ID" in itemIDcollection variable? Or keep "Created" and add an additional "Field" that is related to "ID"? 


Hi Jeremy,

Your requirement is to get all list item IDs from "Parallel List" where items are created < 365 ago and status <> "Completed".

So, you have select the "ID" instead of "Created" in itemIDcollection.

With this, your itemIDcollection will have list of IDs that matches the filter criteria. 

Thanks,

Krishna.


Makes sense. I have made the suggested changes.

Do the settings for my two requirements look fine? I need items created >365 days ago and status <> "Completed" (that is not equal to Completed).


Yes, they are correct, and I corrected my reply with <> Completed.


So I ran the workflow and it Completed, but nothing returned to generate the emails (I have probably 50 that are over 365 days old and have a status <> Completed). Could it be the Site workflow? Here's mine. Could it have an issue with two list workflows under Parallel Test? My project list of data is in the All projects review workflow name. Now just figuring out why it's not generating the emails.


Did you check if itemIDcollection variable has any values? Use "Collection Operation" action to get the count of items in itemIDcollection variable.


Sorry, very new to the Loop and Query list. Can you walk me through/provide steps this or provide a screen shot of what this looks like?


As shown below, add "Collection Operation" action to your workflow after first "Query List" action

Target Collection - itemIDCollection

Select "Count" operation

Store result in "number" data type variable, numCount

Finally log "numCount" and see if it returns > 0 , then your first query list action filtering values satisfying your query.

And 'calcdate' variable is date type?


After adding the "Collection Operation" and my filter from pointing to Created and changing to Date (from my list), the workflow works perfectly. Emails are being generated for projects older than 365 days and a status that <> Completed.

Do you know how to calculate the difference in days (today's date and the project date submission) so that I can include in my email? I want to include that their project is X days old. I have been trying a few things but right now, all emails are defaulting to -707 days.


Hi Jeremy,

I am glad to know that you fixed the issue.

Is your requirement to show how many days old a particular project when sending email to user?

If so, in the Email body, include this function, fn-DateDiffDays(Created,Current Date).


Perfect. I am now capturing the days old in the body of the email. Thanks so much for all of your help. I am providing a final visual of the workflow in case someone else in the future has a similar need.


Reply