Community forum

Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


trevinom
2012-07-10T15:21:01Z
Is there any easy way using available functionality that will allow me to limit the number of job executions to once per day regardless of the number of times the trigger conditions are created?
I am currently using a vb.net script that reads a log file I create with the date stamp i've inserted at the end of a successful run and it's cumbersome.
Any help would be appreciated.
I"m currently using 6.1.1.
I explored the current dependency options ...there is one to deactivate after 1 run, but I want it to stay active for the next day's run.
Sponsor
Forum information
ErikC
2012-07-11T07:40:14Z
Hi trevinom,

What you can do is create a user variable for every job.
Make a condition that will check the content of the variable with the current date.
If the condition is not met, continue else stop.
The 1st task in the job will set the user variable to the current date.

This results in running the job only once per day, even if you trigger it again.

Regards
Erik
Uses Visualcron since 2006.
trevinom
2012-07-11T09:36:53Z
Thank you.
I was hoping to not have to work with conditions.
There should be trigger criteria to make this happen.
Like if a file gets created and variable x = "" then fire off the job.
ErikC
2012-07-12T06:10:25Z
Hi trevinom,

An other solution is:

Create one condition with the following parameters:

{JOB(Active|LastRun|MMddyyyy)} = {DATEFORMAT(MMddyyyy)}

If this condition is met, exit the job else continue.

Now you don't have to create extra variables, but if you run your job manualy, you have to run your job WITH conditions. If there is also a trigger running your job several times a day, than it will only runs once. ;-)

You can use this condition as a generic condition, so you can use it for multiple jobs.

Regards,
Erik
Uses Visualcron since 2006.
trevinom
2012-07-12T12:31:15Z
Have you tried this?
I attempted to set this up, but it goes into infinite loops when I do it.
2016-10-13T13:51:31Z
Hi Trevinom,

I followed this post for the exact same reason. I tried using {JOB(Active|LastRun|MMddyyyy)} != {DATEFORMAT(MMddyyyy)} and was unsuccessful as well. I have changed my condition to {JOB(Active|LastExited|M/d/yyyy)} != {DATEFORMAT(M/d/yyyy)} and it is now working properly. I hope this helps.
Scroll to Top