Questions tagged [windows-task-scheduler]

Use for questions about programmatic modification of task scheduling on any version of the Windows OS.

The MS Windows system scheduler component manages the execution time (time slices) that competing processes & threads are given on available processor cores.

Tag usage

The task is for questions about programmatic modification of task scheduling on any version of the Windows OS. You should also tag questions with their specific Windows version, where relevant.

Related tags

References

Microsoft documentation is the primary source for documentation about Windows Scheduling. You may refer the following topics for more information:

845 questions
6
votes
3 answers

VBScript for creating a scheduled task

I'm trying to create a VBScript that creates a batch file then creates a scheduled task to run the batch file. So far everything I've tried creates the batch file, but does not create the scheduled task and I haven't received any errors. Here is…
takeitback
  • 102
  • 1
  • 2
  • 10
6
votes
3 answers

Set task to run on system startup with cmd/schtasks

I am a bit confused on how to schedule a task to run on system startup as SYSTEM with schtasks command line and I have read MS's documentation on schtasks.exe. Can someone here help me.
user2527738
  • 85
  • 1
  • 1
  • 5
5
votes
1 answer

schtasks automatically enables "Stop the task if it runs longer than 3 days"

I use the batch script to create a scheduled task: schtasks /Create /F /RL highest /SC onlogon /TR "C:\MyFile.exe" /TN "MyDescription" It perfectly runs my application on every user logon. However, it automatically enables "Stop the task if it runs…
Xel Naga
  • 826
  • 11
  • 28
5
votes
1 answer

Adding Principal.RunLevel to Task Scheduler on Python using win32com

After looking around the internet for many days. I've decided to ask my own question. I've done some digging around and found some ways to implement this but i'm stuck. I know that i have to change the logon_type and set the username but it doesn't…
5
votes
1 answer

Windows TaskScheduler DailyTrigger run for a duration of

I'm creating a trigger for a task in Windows using Microsoft.Win32.TaskScheduler.DailyTrigger to run daily at 8am. That task repeats every hour but I want it to stop after 10 hours until it fires up again the next day. In the Windows task scheduler…
Tony
  • 145
  • 1
  • 1
  • 9
5
votes
2 answers

How to export Windows Scheduled task history

On Win2008 R2 - Is there an interface I can go to, or a command I can run, to export the history of one particular task from Windows Task Scheduler? I'll even take all the tasks and then filter the results. The best I can come up with so far is to…
user241099
  • 818
  • 2
  • 7
  • 7
5
votes
1 answer

Pass parameter to windows scheduled task

How do I pass parameters to a scheduled task?
Mark
4
votes
2 answers

Language independent way to specify day parameter for schtasks.exe

I'm trying to add a new task to the Windows Tasks Scheduler with schtasks.exe. The problem I'm having now is to specify the day of the week at which the task should run. From what I could find out that stupid program insists on getting that argument…
Kempeth
  • 1,856
  • 2
  • 22
  • 37
4
votes
1 answer

Python script pops up console when run by scheduler

Possible Duplicate: Run python script without DOS shell appearing I have a python script that Windows Scheduler runs every 5 minutes for me. The script works fine but every time it runs it's loading up the console really quick on my desktop…
Splashlin
  • 7,225
  • 12
  • 46
  • 50
4
votes
6 answers

Win 10 Task Scheduler keeps disabling tasks

I use Task Scheduler to run a .bat file that zips and encrypts files and does a nightly backup of them to an external drive. I have used this for years and it has worked just fine. Starting a couple of months ago, the task is getting disabled in…
AlisonP
  • 41
  • 1
  • 2
4
votes
1 answer

Scheduling Python Script executable in windows 10

I am trying to schedule a python script which has been converted to .exe file but for some reason it is not starting. Although the program does seem to open a cmd type window but the script does not work. Below i have outlined the steps which i…
4
votes
2 answers

Create scheduled task using Task Scheduler Managed Wrapper with "Synchronize across time zones" option disabled

Does anybody know how to create a scheduled task using Task Scheduler Managed Wrapper or Schtasks.exe with "Synchronize across time zones" unchecked.
micram
  • 53
  • 1
  • 5
4
votes
6 answers

Single quotes in schtasks command

I'm trying to use SCHTASKS to create a scheduled task on Windows. The parameters include single quotes. If I create my task manually, it works. In the Windows Task Scheduler GUI, the "Details" (within the action tab) show up like this: powershell…
BSUK
  • 692
  • 1
  • 12
  • 28
4
votes
1 answer

How to run schtasks.exe from Visual Studio 2010 installer?

I have a a Visual Studio 2010 solution with multiple C++ projects, and a windows installer project. The installer works for the most part installing the deployment directories, and applications, and various shortcuts. the last thing I would like…
simon
  • 5,777
  • 7
  • 30
  • 36
4
votes
1 answer

schtasks parameter to disable "execute when user logged on"

I'm trying to set a scheduled task within a VBScript executed as Administrator. This script sets the task without problems as I can see, but it doesn't execute because it's created with the parameter run only when user is logged on. The code is the…
davidrmolla
  • 41
  • 1
  • 3
1 2
3
56 57