Why won't my shutdown reminder show up from Task Scheduler?

November 14, 2026 5 answers
Asked by Nervel_4x

I'm using Task Scheduler to trigger a PowerShell message when Windows logs shutdown event 1074, but the message never appears. I want the user to acknowledge the reminder before shutdown continues. Is this a task configuration issue, or is the shutdown trigger too late?

Answers

m731!rxselect_5

The shutdown event is a tricky place to start. By the time the task reacts, Windows may already be closing applications or ending the user's session. Even if PowerShell launches, there's no guarantee a message window will be visible or that Windows will wait for someone to click OK.

For a reminder that must be acknowledged, the simpler design is to show it before initiating shutdown, then start the shutdown after acknowledgement. That only works if you can control how shutdown is initiated, though. It won't catch every shutdown started elsewhere.

Reply to this answer
Tavby_8m

First separate the task launching from the popup displaying. Have the task write a timestamp to a file, then check Task Scheduler history and the task's last run result. Test the same action with a manual trigger while you're logged in.

Also check which account runs the task and whether it's set to run only when that user is logged on. A task running in a noninteractive session can execute without showing a window on the user's desktop. If you're calling a script file, check the path and any execution policy errors too.

c742!turnstile_8:

If the file gets written during a manual test but not during shutdown, that points toward the trigger or shutdown timing rather than just the message code.

Reply to this answer
Rellby-6k

If you need to respond to shutdowns initiated elsewhere, this is more than passing a command to PowerShell. A running interactive application can receive Windows session-ending messages such as WM_QUERYENDSESSION and use Windows APIs to request a temporary shutdown block.

That's a more involved design, not a guaranteed way to stop every shutdown. You'll need to handle cancellation and time limits, and test what happens if the user doesn't respond. A task launched after event 1074 is not equivalent to an application already listening for that notification.

Reply to this answer
7j!bracket_306

Group Policy shutdown scripts are another option for work that needs to run during shutdown. I wouldn't assume they'll solve the visible reminder, though. Running a shutdown script and getting an interactive acknowledgement from the logged-in user are different problems.

Reply to this answer
7k~shoelace_516

Does the reminder actually have to appear at the moment of shutdown? If not, a scheduled notification while the user is still working may be much easier to make visible. It won't enforce acknowledgement before shutdown, but it avoids relying on a popup during session teardown.

Reply to this answer

Add your answer

Answers are reviewed before publication.

Related Discussions