none
Powershell GUI to Restart after 1 hour deferment RRS feed

  • General discussion

  • Hey Folks!

    Trying to do the following, but haven't found anything that's quite what I need, and am relatively new to powershell.  I've been cobbling together and pouring over at least 10 different scripts and trying to find a resolution.

    I've been tasked with creating a script (with gui) to restart workstations that haven't been rebooted in at least 7 days, and when the prompt comes up, it gives them two options, Reboot, or Defer - 1 Hour.  Then after that hour is up, it comes backup, but only with the Reboot option.

    I borrowed the script from here, which GUI-wise looks great, but I'm having difficulty figuring out the logic for what I need it to do.  I understand the logic, but not sure how to get it done (am taking some powershell courses and have been down many a rabbit hole over the past few weeks on this).  

    I wouldn't be using the schtasks option, just need to set a timer that brings the gui back up after 60 minutes, and only has the reboot option (which I can tie to shutdown /r /t 0).

    I wasn't sure about posting code from the gallery on here, but can do so if it's ok.

    • Changed type Bill_Stewart Tuesday, September 24, 2019 6:24 PM
    • Moved by Bill_Stewart Tuesday, September 24, 2019 6:25 PM This is not "add features to script for me for free" forum
    Friday, August 16, 2019 5:13 PM

All replies

  • The best advice we can give to request to add features to a script (if you're not able to write the code yourself, that is) is to ask the author to add the feature, which you have already done.


    -- Bill Stewart [Bill_Stewart]

    Friday, August 16, 2019 5:21 PM