cancel
Showing results for 
Search instead for 
Did you mean: 

Running my process on an Ad Hoc basis

DavidWood
Level 3
Hello guys!

My process is finished but we've had a request to have it run on an AdHoc basis.

Basically, there's spreadsheet that is maintained, and the process looks for this spreadsheet, gathers the data and processes it.

The problem is, this isn't going to be a regular occurrence and will be mostly ad hoc, so if the process is scheduled and runs every 30 mins, they will be flooded with useless information they already had.

Is there a way I can somehow use BluePrism to say ''Nope, this spreadsheet hasn't been updated since the process last ran fully, don't do anything.'' and ''Okay, the spreadsheet was updated after the last scheduled run, so let's kick it off again''

Thanks in advance!

------------------------------
David Wood
------------------------------
5 REPLIES 5

DavidWood
Level 3
I found a solution I think guys - let me know if this is not best pratice.

At the end of my process I will update a text file with the exact date and time, and call that file ''LastRan''.

At the beginning of my process, I will get the date from that ''LastRan'' file and compare it to the last time the spreadsheet was updated. If the File.Last Written date is > LastRan Date, then the process should run fully. If not, no need to run fully, end.

------------------------------
David Wood
------------------------------

Hi David,

Sounds like a good approach to me, one thing to take care of is permissions on the "LastRan" file. Make sure that it is in a locked down location with only the Runtime Resource user(s) having write access to it, this will prevent unnecessary failures if someone modifies it.

Regards

Chris

------------------------------
Chris McGowan
Senior Technical Consultant
Blue Prism
------------------------------

In case File.Last Written does not work out (for example, if a file with an older modified date is copied/pasted), two other potential options are to save a copy of the file after each run and do a byte-by-byte comparison each time to look for changes, or calculate the MD5 hash of the file and save that to the text file, using that for comparison instead of the last written date.

------------------------------
Nicholas Zejdlik
RPA Developer
------------------------------

Thanks guys for the advice - this worked perfectly! I hit a small snag with our resource timezone and date format being different from ours, but we managed to solve that easily enough.

Thanks again!

------------------------------
David Wood
------------------------------

Sounds like you already solved it, but I like to give suggestions so here I am. 😃 One thing to remember is that you can always use a Blue Prism Queue to hold any information you want. Sometimes I like to avoid creating extra files especially when users can mess them up. It could hold the last modified date or the MD5 hash or anything like that for you to use for comparison later.

------------------------------
Dave Morris
Cano Ai
Atlanta, GA
------------------------------

Dave Morris, 3Ci at Southern Company