0

We have a script that we would like to run at logoff (preferably shutdown). I am already aware of the LGPO option to run a script at shutdown, but we would like the control of Task Scheduler to run this.

What event ID(s) do I need to enter for this to happen?

Reason we want task scheduler is if the script runs for more than x minutes, we would stop the task, and reboot.

Any help is appreciated.

4
  • 1
    I'm too lazy to write an answer, but have you looked in to adding "schtasks /Run " to a GPO logout/shutdown script, and configuring the task elsewhere? Commented Mar 13, 2017 at 20:13
  • That is a unique idea, one I haven't thought of. Testing Time!
    – ztnd13
    Commented Mar 13, 2017 at 20:21
  • Do you mind sharing the script ? And btw have you come across a auto login script ?
    – Elie
    Commented Mar 13, 2017 at 21:59
  • script is proprietary. And what do you mean by auto login? I know how to prevent auto login via scripts
    – ztnd13
    Commented Mar 24, 2017 at 20:27

1 Answer 1

0

We've made a work around with shutdown scripts and are piggybacking off of the logoff ID's as well.

You must log in to answer this question.

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