23

I'm new to using the task scheduler and I'm using it to run a batch file provided online when the computer boots. I r-clicked it and told it to run. It did and all is fine, but the Status of the task is still "Running." I just want to make sure that's okay. Or since it's already done its job, should it end in some way?

The batch file mounts a network drive such that it can be used at the system level.

net use x: \\tplinklogin.net\volume2 /persistent:yes

3 Answers 3

42

The Task Scheduler window doesn't automatically refresh, which could lead you to believe it's still running. Clicking the Refresh link on the right side panel should hopefully show it change.

2
  • 9
    F5 also refreshes it. Very short sighted of Microsoft to not automatically refresh it.
    – Brain2000
    Commented Feb 7, 2017 at 16:50
  • Refresh did not work for me. Still showing "Running". I have another task, that shows "Ready" (after it ran once). Commented Dec 8, 2021 at 23:27
3

I had the same problem - the task worked but the status kept showing Running. One simple thing to try is click on the Task Scheduler Library in the left column. Click Action/Refresh. Presto. Status changed to Ready. That's all it was for me, the task ran fine, just the status didn't update. Hope this helps.

2
  • 2
    Im having this issue. The task succeed, but the status remains "Running" no matter if i refresh or not.
    – bitshift
    Commented Feb 17, 2017 at 20:02
  • 1
    On digging in a bit again, I found the issue. I was pointing to a script in a different folder than I thought. The actual script being used had a line of code using Read-Host -Prompt "Press Enter to exit" which will put the script in interactive mode.
    – bitshift
    Commented Feb 17, 2017 at 20:51
0

If you really want to make sure it's not still "Running." then using this reference for Win+R > CMD https://ss64.com/nt/schtasks.html add to your:

Task Scheduler > TASKNAME > Properties > Actions > Start a program > script >

SCHTASKS /End /TN "TASKNAME"

OR

Task Scheduler > TASKNAME > Properties > Actions > Start a program > script > "B:\Code\stoptask.bat"

copy below script to Win+R notepad and File > Save as... stoptask.bat

REM .bat Windows / DOS CMS batch script
@echo off
REM more commands can go here
REM end Scheduled Task once run
SCHTASKS /End /TN "TASKNAME"

“We don’t wake up for less than $10,000 a day” ~ Linda Evangelista

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .