logo
Windows 10 Fixed Windows 10/11 Task Scheduler Batch File Not Executing

Fixed Windows 10/11 Task Scheduler Batch File Not Executing

By Achilles Hill | Last Updated

Have you ever been in this situation? Created a batch file, created a basic task in the Task Scheduler and wanted to automatically delete the contents of the temporary folder when the PC starts up. But when the PC starts up, nothing happens. In this post, I will share you the most effective ways to fix Windows 10/11 task scheduler batch file not executing issue.

fixed windows 10 11 task scheduler batch file not executing

Way 1: Ensure to get file or folder full control permissions

Step 1: Ensure that the account you use to run the script in Task Scheduler has full control over the folder containing the script, the script itself, and any folders/files touched by the script when it runs.

For instance, I created the following batch file.

net stop "SQL Server Reporting Services (MSSQLSERVER)" 

timeout /t 10

net start "SQL Server Reporting Services (MSSQLSERVER)"

enter the script

Step 2: Save the .BAT file in my Documents folder. The path is C:\Users\username\Documents. Go back to C:\Users\username, right-click on the Documents folder and clicked on Properties.

right click to open properties

Step 3: Move to the Security tab, the user account Angelia has been added and given full control permissions. Now repeat the above steps for the folder containing the script and for the script itself. Don't assume that giving permissions to the folder containing the script is sufficient. Finally, set permissions on any files and folders that the script will interact with.

get full control

Way 2: Adjust Task Scheduler settings

Step 1: Type Task Scheduler in the Start menu bar and click Open.

Step 2: Select Properties under the Action tab.

click properties

Step 3: Move to the Actions tab and click on the New option below.

click new option

Step 4: Under Program/script, type: C:WindowsSystem32cmd.exe. Then type /c start "" "C:location_to_batch_fileyour_batch_file.fs" in the Add arguments (optional). Finally click OK to finish the settings.

enter the code in program

Way 3: Check the Run with highest privileges option

In the Task Scheduler, double-click a batch file task to open, under the General tab, select Run with highest privileges and click OK to apply the settings.

run with highest privileges

Way 4: Update your system to the latest version

Step 1: Use Windows + I to open Settings, find and click Update & Security.

Step 2: Under the Windows Update, click Check for updates. If there are any Windows updates available, please upgrade to the latest version.

check for updates

Related Articles: