November Happy Hour will be moved to Thursday December 5th.
November Happy Hour will be moved to Thursday December 5th.
There's no built in functionality for this. What you can do is to run the job every minute and check in the job if it is time to run the job. Not an ultimate solution, but it solves the problem.
/Erik
You can only schedule a job on a fixed recurring interval, like for example every 2nd minute or every 3rd day or every 7th year
If you want the job to run at 09:00 12:00 and 21:00 every day, you could do it by scheduling the job as three individual "jobs", each with an interval of
1 day and exavtly set the nextExecute to the desired times.
This requires some coding however, as this functionality is not exposed through the Admin user interface.
Have a look at the ScheduledJob class (in EPiServer.DataAbstraction), it would let you create/save/load jobs programmatically.
/johan
Erik,
Although I think this is the most effective answer, we have gone down the route of running the job once an hour, which doesn't involve any code changes, and should hide within the timeslot of the other extract.
Many thanks for taking the time to answer to you both.
I had similar issue, but had to run ScheduledJob with some interval between job completion. So I created method SetNextRun in ScheduledJob class:
private void SetNextRun()
{
var job = ScheduledJob.Load(ScheduledJobId);
if (job.IsEnabled)
{
job.NextExecution = DateTime.Now.AddSeconds(10);
job.Save();
}
}
But it is possible also to use it for scheduling job to particular time.
I also had method for job to deactivate itself if it's done:
private void Deactivate()
{
var job = ScheduledJob.Load(ScheduledJobId);
job.IsEnabled = false;
job.Save();
}
Hi,
I have a job which needs to be synchronised with a data extract which happens at specific times of the day, but I have been unable to find any resources for how this could be achieved.
Ideally, I would want to be able to schedule several hours throughout the day.
Any help would be much appreciated.
Many thanks,
Paul