I have a workflow that is triggered by an email that is received through an Email Receive element with job data attached in a CSV format. This singular email is presently received on Monday and Thursday morning at 5AM.
I would like to trigger a notification email IF no data is received within a time window, such as 5AM-10AM on those given days.
Any ideas on creating this functionality?
I am a novice at scripting so please keep that in mind.
--Evan
Check if a file was submitted within a time of day
-
- Member
- Posts: 25
- Joined: Thu Jan 07, 2016 8:42 pm
-
- Member
- Posts: 93
- Joined: Fri Jul 08, 2011 10:31 am
- Location: The Netherlands
Re: Check if a file was submitted within a time of day
This would require two scripts.
The first script should set a variable (flag) in the global-data of Switch. This flag gets set when a mail is received.
See topic "Maintaining global data" under "Scripting reference/Flow element module/Environment class" in the scripting manual.
The second script, which is timer-fired, has two tasks:
1) Reset the flag is time is before 5:00
2) Create a dummy-file as trigger if time is after 10:00 AND the flag is not set by the first script.
If you want it should even be possible to combine the two scripts into one, but i think this example is more straight forward.
Hope it helps
The first script should set a variable (flag) in the global-data of Switch. This flag gets set when a mail is received.
See topic "Maintaining global data" under "Scripting reference/Flow element module/Environment class" in the scripting manual.
The second script, which is timer-fired, has two tasks:
1) Reset the flag is time is before 5:00
2) Create a dummy-file as trigger if time is after 10:00 AND the flag is not set by the first script.
If you want it should even be possible to combine the two scripts into one, but i think this example is more straight forward.
Hope it helps