how to schedule a task on all weekdays and then disable only on holidays

18,076

Solution 1

If this is a Windows Server 2008 - you can try the below from the Task Scheduler -

Screenshot for the Task Scheduler Trigger window pane

You can then uncheck the days you dont want the task to run as I have highlighted in blue.

I believe this is what you are looking for...

Solution 2

Well, One way I see to do this is to the task to end on a holiday, then have a second task starting on the next working day, and ending that task the next holiday. Rinse and repeat per holiday.

enter image description here

The newer versions of task scheduler does seem to let you string events together, but I don't see any option not to run a task on a specific day.

Share:
18,076

Related videos on Youtube

user47289
Author by

user47289

Updated on September 18, 2022

Comments

  • user47289
    user47289 over 1 year

    We would like to scheduled a task on Windows Server on all weekdays. At the same time, the task should be disabled on the holidays. Please advise.

    • hey
      hey over 11 years
      The tricky thing might be how task scheduler knows its a holiday. I can't think of any cron-like system that is aware of this.
    • user47289
      user47289 over 11 years
      May be, can we have a annual maintenance activity to disable the activity for those holidays?
    • hey
      hey over 11 years
      Might want to add the version of windows to your question. Task scheduler on newer and older version of windows are VERY different.
    • user47289
      user47289 over 11 years
      OS Version : Win 2003 Server Enterprise edition
    • user47289
      user47289 over 11 years
      What is the need for this? On Business holidays and weekends, we do not want to run a process.
  • user47289
    user47289 over 11 years
    This looks cool. Say we have 10 business holidays, then will have 10 scheduled tasks. Thanks a lot.
  • user47289
    user47289 over 11 years
    Could please give more info on string events together on the new task scheduler.