1

Is there any possibility to make the Quartz.Net trigger to work based on weekly basis. I have done up the rest of the things. Its urgent. Please guide me how can i do this.

Dheyvendaran
  • 175
  • 1
  • 4
  • 12

1 Answers1

1

Create a cron trigger with a format such as "0 22 30 ? * MON". This means it will run at the time 22:30:00 every Monday. The year parameter is omitted. The day-of-month is irrelevant (hence '?') and the month is set to every month ('*').

The configuration in your jobs config file would be:

    <trigger>
      <cron>
        <name>MondayTrigger</name>
        <group>MyGroup</group>
        <description>A description</description>
        <job-name>Job1</job-name>
        <job-group>JobGroup1</job-group>
        <cron-expression>0 22 30 ? * MON</cron-expression>
      </cron>
    </trigger>
Josh Gallagher
  • 5,211
  • 2
  • 33
  • 60