Content deleted Content added
mNo edit summary |
Windows Task Scheduler is included in ReactOS too, added it to infobox |
||
(37 intermediate revisions by 20 users not shown) | |||
Line 1:
{{Short description|Computer application of Microsoft Windows}}
{{distinguish|Windows Task Manager}}
{{Use mdy dates|date=December 2022}}
{{Infobox software
| name = Windows Task
| screenshot
| screenshot_size
| caption
| developer
| released = {{Start date and age|1995}}
| other_names
| replaces
| service_name
| programming language
| included with = * [[
* [[Windows
* [[Windows 2000]] and later<br />(Windows NT family)
| genre = [[Windows service]]▼
* [[ReactOS]]<br />(Windows NT-like)
}}
'''Task Scheduler''' (formerly '''Scheduled Tasks''')<ref name=":0" /> is a
Task Scheduler can be compared to [[cron]] or [[anacron]] on [[Unix-like]] [[operating system]]s. This service should not be confused with the [[Scheduling (computing)#Windows|scheduler]], which is a core component of the OS [[kernel (
==Versions==
Line 39 ⟶ 29:
| url = http://msdn2.microsoft.com/en-us/library/aa446802.aspx
| title = About the Task Scheduler
| access-date = October 6, 2007
| work = [[MSDN]]
| publisher = [[Microsoft]]
}}</ref> It runs as a [[Windows Service]], and the task definitions and schedules are stored in [[Binary file|binary]] <code>.job</code> files. Tasks are manipulated directly by manipulating the <code>.job</code> files. Each task corresponds to single action. On [[Windows 95]] (with [[Internet Explorer 4.0]] or later), [[Windows 98]] and [[Windows Me]], the Task Scheduler runs as an ordinary program, <code>mstask.exe</code>. It also displays a status icon in the notification area on Windows 95 and Windows 98 and runs as a hidden service on Windows Me, but can be made to show a tray icon.<ref name=":0">{{cite web|url=http://support.microsoft.com/kb/272962|title=How to Enable the Scheduled Tasks Icon in Windows Me|date=January 29, 2007|work=Support|publisher=[[Microsoft]]|url-status=dead|archive-url=https://web.archive.org/web/20080130185556/http://support.microsoft.com/kb/272962|archive-date=January 30, 2008}}</ref> Computer programs and [[Scripting language|scripts]] can access the service through six [[Component Object Model|COM]] [[Interface (computing)|interfaces]].<ref>{{Cite web|url = https://msdn.microsoft.com/en-us/library/windows/desktop/aa383581%28v=vs.85%29.aspx|title = Task Scheduler 1.0 Interfaces|access-date =
In addition to the graphical user interface for Task Scheduler in [[Control Panel (Windows)|Control Panel]], Windows provides two command-line tools for managing scheduled task: <code>[[at (command)|at.exe]]</code> (deprecated)<ref>{{cite web|url=https://www.computerhope.com/at.htm|title=MS-DOS and Windows command line at command|access-date=March 7, 2021|website=Computer Hope}}</ref> and <code>schtasks.exe</code>.<ref name="Mueller-2010" /><ref>{{cite web|title=Schtasks|url=https://technet.microsoft.com/en-us/library/bb490996.aspx|work=[[Microsoft TechNet]]|publisher=[[Microsoft]]|access-date=
===Task Scheduler 2.0===
Task Scheduler 2.0 was introduced with [[Windows Vista]]<ref>{{cite book|author1-first=Robert|author1-last=Cowart|author2-first=Brian|author2-last=Knittel|year=2008|title=Special Edition Using Microsoft Windows Vista|publisher=[[Que Publishing]]|isbn=978-0789737816}}</ref> and included in [[Windows Server 2008]] as well.<ref name="VBSPR">{{cite book|
author1-first=Adrian|author1-last=Kingsley-Hughes|author2-first=Kathie|author2-last=Kingsley-Hughes|author3-first=Daniel |author3-last=Read|year=2011|title=VBScript Programmer's Reference|publisher=[[John Wiley & Sons]]|isbn=978-1118058695}}</ref><ref name="about"/> The redesigned Task Scheduler user interface is now based on [[Microsoft Management Console|Management Console]]. In addition to running tasks on scheduled times or specified intervals, Task Scheduler 2.0 also supports calendar and event-based triggers, such as starting a task when a particular event is logged to the ''event log'', or when a combination of events has occurred. Also, several tasks that are triggered by the same event can be configured to run either simultaneously or in a pre-determined chained sequence of a series of actions, instead of having to create multiple scheduled tasks. Tasks can also be configured to run based on system status such as being idle for a pre-configured amount of time, on startup,<ref>{{Cite web|url=https://www.pcworld.com/article/2603028/automate-your-morning-programs-with-windows-task-scheduler.html |title=Automate your morning programs with Windows Task Scheduler |last1=Paul|first1=Ian |work=[[PCWorld]] |date=September 5, 2014 |access-date=March 15, 2021 }}</ref> logoff, or only during or for a specified time. [[XPath]] expressions can be used to filter events from the [[Windows Event Log]]. Tasks can also be delayed for a specified time after the triggering event has occurred, or repeat until some other event occurs. Actions that need to be done if a task fails can also be configured. The actions that can be taken in response to triggers, both event-based as well as time-based, not only include launching applications but also take a number of custom actions. Task Scheduler includes a number of actions built-in, spanning a number of applications; including send an e-mail, show a message box, or fire a [[Component Object Model|COM]] handler when it is triggered. Custom actions can also be specified using the Task Scheduler API. Task Scheduler keeps a history log of all execution details of all the tasks.<ref name="taskscheduler">{{cite web |url=http://www.microsoft.com/technet/windowsvista/mgmntops/taskschd.mspx
|title=Windows Vista Task Scheduler
Line 58 ⟶ 55:
|archive-date=April 12, 2006
}}</ref> Windows Vista uses Task Scheduler 2.0 to run various system-level tasks;<ref>{{cite web|url=http://support.microsoft.com/kb/939039|title=Description of the scheduled tasks in Windows Vista|date=August 24, 2007|url-status=live|archive-url=https://web.archive.org/web/20071022033307/http://support.microsoft.com/kb/939039|archive-date=October 22, 2007}}</ref> consequently, the Task Scheduler service can no longer be disabled (except with a simple registry tweak).
[[Image:Windows 7 Task Scheduler.png|thumb|right|Task Scheduler 2.0 in [[Windows 7]]]]
Task Scheduler 2.0 exposes an [[API]] to allow computer programs and scripts create tasks.<ref name="VBSPR" /><ref name="kerr">{{cite web
| url = http://msdn.microsoft.com/msdnmag/issues/07/10/WindowsCPP/
| title = Task Scheduler 2.0
Line 65 ⟶ 62:
| work = [[MSDN]]
| publisher = [[Microsoft]]
| access-date = October 6, 2007
| date = October 2007
| url-status=dead
| archive-url = https://web.archive.org/web/20071226223747/http://msdn.microsoft.com/msdnmag/issues/07/10/WindowsCPP/
| archive-date = December 26, 2007
}}</ref> It consists of 42 [[Component Object Model|COM]] [[Interface (computing)|interfaces]].<ref>{{Cite web|url = https://msdn.microsoft.com/en-us/library/aa383600%28v=vs.85%29.aspx|title = Task Scheduler 2.0 Interfaces|access-date =
====Other features====
Line 83 ⟶ 80:
| work = [[MSDN]]
| publisher = [[Microsoft]]
| access-date = October 6, 2007
}}</ref>
==Column 'Last Result'==
The Last Result column displays a completion code. The common codes for scheduled tasks are:<ref>{{cite web|title=How to troubleshoot scheduled tasks in Windows XP and in Windows Server 2003|url=http://support.microsoft.com/kb/308558|work=Support|publisher=[[Microsoft]]|access-date=September 3
{{Div col|small=yes}}
* 0 or 0x0: The operation completed successfully.
* 1 or 0x1: Incorrect function called or unknown function called.
Line 135 ⟶ 133:
* 0x80041327: The task has properties that are not compatible with earlier versions of Windows.
* 0x80041328: The task settings do not allow the task to start on demand.
* 0x80070002: The Task Scheduler cannot find the file.
* 0x800710E0: The operator or administrator has refused the request.
* 0xC000013A: The application terminated as a result of a CTRL+C.
* 0xC0000142: The application failed to initialize properly.
{{Div col end}}
==Bugs==
On Windows 2000 and Windows XP,
On Windows Vista or Windows Server 2008,
</ref>
==See also==
*[[cron]], job scheduler for Unix-like operating systems
==References==
{{Reflist}}
==Further reading==
* {{cite book|author1-last=Leonhard|author1-first=Woody|author2-last=Rusen|author2-first=Ciprian|year=2021|title=Windows 10 All-in-One For Dummies|publisher=[[John Wiley & Sons]]|isbn=978-1119680574}}
* {{cite book|author1-last=Knittel|author1-first=Brian|author2-last=McFedries|author2-first=Paul|year=2014|title=Windows 8.1 in Depth|publisher=[[Que Publishing]]|isbn=978-0789752819}}
* {{cite book|author1-last=Bott|author1-first=Ed|author2-last=Siechert|author2-first=Carl|author3-last=Stinson|author3-first=Craig|year=2009|title=Windows 7 Inside Out|publisher=[[Pearson Education]]|isbn=978-0735636842}}
* {{cite book|author1-last=Ruest|author1-first=Danielle|author2-last=Ruest|author2-first=Nelson|year=2008|title=Microsoft Windows Server 2008: The Complete Reference|publisher=[[McGraw-Hill Education]]|isbn=978-0071596466}}
* {{cite book|author1-last=Cowart|author1-first=Robert|author2-last=Knittel|author2-first=Brian|year=2008|title=Special Edition Using Microsoft Windows Vista|publisher=[[Que Publishing|Que]]|isbn=978-0789737816}}
==External links==
|