+ Start a Discussion
ArunaAruna 

In production I need to schedule 2 schedule class one is 7:00 AM other one is @ 7:30 AM-Prod Urgent

Hi there .

In production I need to schedule 2 schedule class one is 7:00 AM other one is @ 7:30 AM MON - FRI and JAN-DEC and 2016-2020.
I need confirmation is below script is correct ? is below script runs every day @ 7: AM and 7: 30 AM from MON-FRI and JAN-DEC and 2016-2020

//Scedule a class every day @ 7 AM except weekends from 2016-2020
//Seconds Minutes Hours Day_of_month Month Day_of_week optional_year
System.schedule('Sch1', '0 00 7 ? * MON-FRI 2016-2020', Sch1);

//Scedule a class every day @ 7 :30AM except weekends from 2016-2020
//Seconds Minutes Hours Day_of_month Month Day_of_week optional_year
System.schedule('Sch2', '0 30 7 ? * MON-FRI 2016-2020',Sch2);

Please any confirm  if it correct or not . if it is not please correct my script and send me .

Thank you:)
harsha__charsha__c
Yes, This should work exactly as you are expecting.

- Harsha