What is the correct actions to use when I want to create a workflow to collect all the events created and modified that day on the calendar. I'm having a hard time because I only use nintex workflow once to create a workflow to collect all the events. But I'm having a hard time collecting the events created and modified on a specific date or the present day. Any suggestion would be a great help. Thanks in advance
I'd use a scheduled site workflow. That workflow uses a query list action that filters the calendar list to only include events created or modified at the current date.
Afterwards you can loop through the results and do whatever you want with the events found.
Hi Enrico,
Thank you I already solve it but I want to include another feature in my workflow that in the table it will also show what is the item that has been modified in the calendar. for example I have a list of Title, Start time, End time and Location. The user change the location how can I pin point that the changed item is the location.
Another example is the original start time is 5pm then the user change it to 6pm. What I would like to know is how can I recover the time before being modified. This is what the ideal input:
Title | Old Schedule | New Schedule |
Router Maintenance | 5:00PM | 6:00PM |
Getting the new schedule is quite easy. But how can I get the old schedule which was already has been overwritten by the new schedule.
What you're asking is how to grab the previous value of a field. While you can trigger workflows to start when a specific field changes, I don't know of an easy way to grab the previous data and use it. The solution I've used for scenarios like this in the past is to create a previous value field in your list for the fields you want the previous information for. Then you'll have to build a workflow that updates the field at the appropriate times after you've used the previous date information. Here is an example of how that would work.
New Event
When a new event is created, a workflow set's the Previous Date field to the Event Date
Event | Event Date | Previous Date |
---|---|---|
Router Maintenance | 5:00 PM | 5:00 PM |
Date is Changed
When the date is changed, the previous date will have the old date information.
1. Run your workflow that does whatever you need it to do with the old date information.
Event | Event Date | Previous Date |
---|---|---|
Router Maintenance | 6:00 PM | 5:00 PM |
2. After you have used the old date information, you then need to set the Previous Date again to the current Event Date
Event | Event Date | Previous Date |
---|---|---|
Router Maintenance | 6:00 PM | 6:00 PM |
You would need to have a "Previous" field for which ever elements you want to capture the previous information for.
Hi Brendan,
Can you explain further the workflow because I'm really new in creating workflows. What I understand in your explanation is that. In my list I will have a column Event, Event Date (Which is Start Time and End Time) and also Previous Date(Which is Start Time and End Time). Now in the workflow I think I will Query the events and loop through every one of them and insert them as reference like {WorkflowVariable:Event}, {WorkflowVariable:EventDate} and {WorkflowVariable:PreviousDate} in a variable. So I think when the user is modifying the event they will also fill the new event date and the previous date?
You will need multiple workflows. I would not make the user populate the previous date field. I would do this through the workflow only.
- First Workflow runs every time a new event is created and copies the event date the user entered into the previous date field. (I would suggest making the event date a required field to ensure there is something to copy into the previous date field).
- Second Workflow is the one where you query all the events and do whatever process you want with the items that have changed. As part of you query, you can compare the current date and previous date fields. If they match, then they have not changed. If they don't match, then that means that after the event was created, the user went and changed the event date. After you find all the events where the fields changed, and you do whatever processing you need to do (yes, you can insert the data as references as you have noted), the last step of the workflow needs to be to set the previous date field to match the current date again.
Hope that makes sense.
Hi Brendan,
Sorry for asking this but I am really new to the nintex workflow. what action should I use to get the event date. Should I use the copy item action? Thank you in advance.
It depends for what purpose you are using the date and what step you are in the process. Could you provide a screen shot of your workflow and where you are getting stuck as that will help to be able to give the best answer. Thanks.
This is the first workflow I did. It is set to start when an event is created. It will update 2 fields which is Previous Start Time (UTC) and Previous End Time (UTC). So when the user modify the event the field Previous Start Time (UTC) and Previous End Time (UTC) will remain as is. But my problem is what if they need to modify it again the previous value will remain the same. I can't seem to think of a workflow that every time they modify the event it will store it's previous start and end time.
I think using the update item action is wrong. Because my workflow will only work if it is modified one time only. It will not work if the event is modified several times
Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.