Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Task Scheduler recognizes only first trigger


06 Dec 2009   #1

Windows 7 Home Premium (32 bit)
 
 
Task Scheduler recognizes only first trigger

Hi,

the problem is if I create a new task for the task scheduler which is having multiple triggers, only the first entered trigger is recogized and used.

E.g., I have two weekly triggers to execute a program. The first selects Mon, Tue, Wed, Thu, and Fri to run the program. The second selects the weekend to run the program, i.e. Sat, Sun.

--> Now, the program starts only on Mon to Fri. The Sat/Sun trigger is neglected and the program doesn't start on the weekend.

If I delete the first Mon-Fri trigger, suddenly the weekend trigger is recognized.

If I then add the Mon-Fri trigger again (now as second trigger), it remains unoticed, i.e., only the weekend trigger remains used.

In all cases I made sure the triggers were set "active".

Any ideas how to solve that?

Thx

My System SpecsSystem Spec
.

06 Dec 2009   #2

Microsoft Community Contributor Award Recipient

Windows 7 Home Premium SP1, clean install, upgrade disc
 
 

Quote   Quote: Originally Posted by cerrick View Post
Hi,

the problem is if I create a new task for the task scheduler which is having multiple triggers, only the first entered trigger is recogized and used.

E.g., I have two weekly triggers to execute a program. The first selects Mon, Tue, Wed, Thu, and Fri to run the program. The second selects the weekend to run the program, i.e. Sat, Sun.

--> Now, the program starts only on Mon to Fri. The Sat/Sun trigger is neglected and the program doesn't start on the weekend.

If I delete the first Mon-Fri trigger, suddenly the weekend trigger is recognized.

If I then add the Mon-Fri trigger again (now as second trigger), it remains unoticed, i.e., only the weekend trigger remains used.

In all cases I made sure the triggers were set "active".

Any ideas how to solve that?

Thx
If your new task, is something like system restore, which was already on task schdduler, it will run accordcing to schedule, if it has not run within a specificed period of time. System restore will run on schedule if it has not run within the last 24 hours.
My System SpecsSystem Spec
07 Dec 2009   #3

Windows 7 Home Premium (32 bit)
 
 

Quote   Quote: Originally Posted by richc46 View Post
If your new task, is something like system restore, which was already on task schdduler, it will run accordcing to schedule, if it has not run within a specificed period of time. System restore will run on schedule if it has not run within the last 24 hours.
Thanks for your reply. I try to automatically shutdown my PC (shutdown -s -f -t 600). This should happen on different times wrt whether it's Mon-Fri or Sat-Sun; hence multiple triggers.

Well, a workaround is to set up multiple tasks, each having one trigger.

I wonder, does anyone else have the same problem described in the original post?
My System SpecsSystem Spec
.


28 Dec 2012   #4

Windows 7 Enterprise 32-bit
 
 

I have the same issue. I think your 2 triggers are in conflict in a sense. The first one allows weekdays but not weekends. Since the first trigger has not expired, I think that second trigger is ignored because it wants to run on weekends which is not allowed by the first trigger. So your solution of creating separate tasks is the best solution I can think of.
My System SpecsSystem Spec
29 Dec 2012   #5

Windows 7 ultimate x64
 
 

What are your trigger and action conditions ???
My System SpecsSystem Spec
30 Dec 2012   #6

Windows 7 Enterprise 32-bit
 
 

Right. Let's consider a task with 2 triggers cooked up as a demonstration.
One trigger is weekly Monday through Friday.
The other is monthly on the evening of the last Sunday of each month.
Right now, it is the morning of the last Sunday of the month.
The action is to run a meaningless .BAT file.

Case 1: The weekly trigger is coded first, the monthly one second.
Result: The task is scheduled for Monday but I expected it Sunday. The monthly (second) trigger is ignored.

Case 2: Same order for triggers as Case 1, but disable the weekly trigger.
Result: The task is scheduled for Sunday as expected.

Case3: The monthly trigger is coded first, the weekly one second
Result: The task is scheduled for Sunday as expected.

Case4: Change the monthly trigger to run the first Sunday rather than the last. Same trigger order as case 3.
Result: The task is scheduled for the first Sunday but I was expecting Monday. The weekly (second) trigger is ignored.

I have done similar testing with combinations of (a) 2 weekly triggers, (b) a one-time and a weekly trigger, (c) 2 one-time triggers. For each combination, I see similar results. Note that the case of the one-time triggers works if the triggers are entered in chronological scheduled-time order .

I, therefore, conclude that where 2 triggers overlap in enabled period, the first takes precedence and the second is ignored
My System SpecsSystem Spec
31 Dec 2012   #7

Win 7 Pro x64 SP1, Win 7 Ult x86 SP1
 
 

@Jerkasaurus
+1 - Very nice explanation and testing!

To me, it seems the easiest solution is to create a new scheduled task for each Scheduled "Time Based" trigger.

I'll add this.
I've set up scheduled tasks with multiple triggers that are not "time based" (on a schedule) and the multiple triggers work in a single task.

i.e.
I want a task to run any time a PC "starts up".
The PC may statup from a Wakeup, Hibernate (Resume), or Power On start up.

I set up a trigger for a Wakeup/Hibernate (Event) startup.
I had to set up another trigger for a Power On start up.
Each of these triggers work in a single scheduled task.

Thanks again for the explanation, and hopefully I'll remember this !
My System SpecsSystem Spec
24 Oct 2013   #8

Windows 7 Enterprise 64bit
 
 

i'll update this old post as it's the first i found with my problem.
turns out it is only a display problem (i didn't test this) and microsoft has a hotfix for this.
http://support.microsoft.com/kb/2495489

i have this problem scheduling monthly reboots and have a different schedule for the holiday months (Nov & Dec). these tasks kick off System Center Orchestrator jobs and we have several dozen to kick off. reallllly don't want to create multiple tasks for each runbook kickoff.
My System SpecsSystem Spec
Reply

 Task Scheduler recognizes only first trigger




Thread Tools



Similar help and support threads for2: Task Scheduler recognizes only first trigger
Thread Forum
How to trigger 'task scheduler' on new wifi connection? Network & Sharing
Solved Task scheduler: trigger on screensaver event possible? Performance & Maintenance
Task scheduler unable to load task status/active tasks at startup. Performance & Maintenance
Function of time field in New Trigger window Task Scheduler? Customization
Scheduler/trigger events General Discussion
Help with using idle trigger in Win Task Scheduler Performance & Maintenance
Task Scheduler Trigger @ Program shutdown Performance & Maintenance

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 03:29 PM.
Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App
  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33