title: quartz.net simple example as per the time given
body: <p>I am new to quartz.net. I want to build a simple window based application which scheduled the task. Suppose I have 4 task ans it start and end time
  Example</p>
  
  <pre><code>Breakfast ; 8:00;8:30
  Lunch;13:00;13:30
  dinner;19:30;20:00
  </code></pre>
  
  <p>Now I want when I click on button at 8:00 AM a message box should appear with a text "breakfast started!!!" at 8:30 AM again a message box should appear with a text as "Breakfast end!!!" and so on.</p>
  
  <p>I had gone through <a href="http://www.quartz-scheduler.net/documentation/quartz-2.x/tutorial/" rel="nofollow noreferrer">tutorial</a>. But confuse how to proceed. Can any one help me out?</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>Is it possible to use one job and one triggers for this?</p>
  
  <pre><code>IScheduler scheduler = StdSchedulerFactory.GetDefaultScheduler();
  
  
                  for (int i = 0; i &lt; listBox1.Items.Count; i++)
                  {
                      string[] strArr = Regex.Split(listBox1.Items[i].ToString(), @";", RegexOptions.Multiline);
                      // define the job and tie it to our HelloJob class
                      IJobDetail jobStart = JobBuilder.Create&lt;HelloJob&gt;()
          .WithIdentity("job" + i, "group1") // name "myJob", group "group1"
          .StoreDurably()
          .UsingJobData("jobSays", strArr[0].ToUpper().Trim() + " " + "starts")
          .Build();
  
                      string[] ArrStart = strArr[1].Trim().Split(':');
  
                      ITrigger triggerstart = TriggerBuilder.Create()
                          .WithIdentity("trigger" + i, "group1")
  
  .WithSchedule(CronScheduleBuilder.DailyAtHourAndMinute(Convert.ToInt32(ArrStart[0]), Convert.ToInt32(ArrStart[1])))
                          // .WithSimpleSchedule(x =&gt; x.WithMisfireHandlingInstructionIgnoreMisfires()
  
  
                                      .ForJob(jobStart)
                                  .Build();
                      // .WithSchedule(CronScheduleBuilder.CronSchedule("0 4 06 1/1 * ? *"))
  
                      // Tell quartz to schedule the job using our trigger
                      scheduler.ScheduleJob(jobStart, triggerstart);
                      scheduler.Start();
                      string[] Arrend = strArr[2].Trim().Split(':');
                      IJobDetail jobend = JobBuilder.Create&lt;HelloJob&gt;()
          .WithIdentity("job1" + i, "group1")
          .StoreDurably()
          .UsingJobData("jobSays", strArr[0].ToUpper().Trim() + " " + "end")
          .Build();
  
                      ITrigger triggerend = TriggerBuilder.Create()
                          .WithIdentity("trigger1" + i, "group1")
  
  .WithSchedule(CronScheduleBuilder.DailyAtHourAndMinute(Convert.ToInt32(Arrend[0]), Convert.ToInt32(Arrend[1])))
                          // .WithSimpleSchedule(x =&gt; x.WithMisfireHandlingInstructionIgnoreMisfires()
  
  
                                      .ForJob(jobend)
                                  .Build();
  
  
                      scheduler.ScheduleJob(jobend, triggerend);
                      scheduler.Start();
                  }
  
  
              }
              catch (SchedulerException se)
              {
                  Console.WriteLine("Scheduler Exception : " + se);
              }
          }
          public class HelloJob : IJob
          {
              public void Execute(IJobExecutionContext context)
              {
                  JobKey key = context.JobDetail.Key;
                  JobDataMap dataMap = context.JobDetail.JobDataMap;
                  string jobSays = dataMap.GetString("jobSays");
                  MessageBox.Show(jobSays);
              }
          }
  </code></pre>