Search code examples
c#.netcronquartz.netcronexpression

Issue in Quartz.Net Cron Exrpession


I have used http://www.cronmaker.com/ to generate Cron Expression I need to run job every 45 minutes but seems there is something wrong with Cron expression or Quart.Net. Please look at following outputs and suggest me solutions.


Cron format: 0 0/45 * 1/1 * ? *

Next scheduled dates

1.Tuesday, August 16, 2016 1:45 PM

2.Tuesday, August 16, 2016 2:00 PM

3.Tuesday, August 16, 2016 2:45 PM

4.Tuesday, August 16, 2016 3:00 PM

5.Tuesday, August 16, 2016 3:45 PM

Thanks in Advances


Solution

  • You can't do that in one line of cron magic. You need three.

    0,45  0-23/3 * * * foo
    30    1-23/3 * * * foo
    15    2-23/3 * * * foo