I would like to know where Windows stores information for Scheduled Tasks. I would like to be able to find the reference for the name, schedule, or command to run associated
I needed to delete some tasks as in a script as the final part of a system build.
I discovered you can just delete them eg:
@echo ..Audit hardware
"\\vs-files\General\0000 IT\Bginfo.exe" "\\czwgbak\Software\_Build2015\AuditWorkstation.bgi" /timer:0 /Silent /NOLICPROMPT
@echo delete Scan Setup inis
If not exist %systemroot%\System32\Tasks\ASUS\nul goto reg
rd %systemroot%\System32\Tasks\ASUS /S /Q
:reg
etc...
In Windows 7 they are stored in files under "Windows\System32\Tasks". The files are XML, so you could create and edit task files there.
Other versions of Windows I think they are stored in "%SystemRoot%\Tasks"
Windows stores scheduled tasks as XML files, AND in the registry.
You can find them in a few places:
Filesystem:
%systemroot%\System32\Tasks
%systemroot%\Tasks
Registry:
HKLM\Software\Microsoft\Windows NT\CurrentVersion\Schedule\Taskcache\Tasks
HKLM\Software\Microsoft\Windows NT\CurrentVersion\Schedule\Taskcache\Tree
Note: You can't edit the XML files directly in \Tasks for security reasons. See here for more information: https://serverfault.com/questions/440496/ok-to-edit-tasks-xml-file-in-c-windows-system32-tasks
To work with importing the XML files without going through the scheduled task UI you can look at these:
Schtasks.exe
Powershell Scheduled Task Cmdlets