Closed pilgi3 closed 4 years ago
this is the basis for the script, https://www.itninja.com/blog/view/reboot-required-toast-notifications-for-windows-machines
the thing is, if you open a PS window and paste it in and run it, it works, every time i try to get it to run any other way, it wont.
I tried on my test clients and yes you are right. Works local but not remote ...
changed it to:
Set-Location (Get-ItemProperty("HKLM:\SOFTWARE\Microsoft\SMS\Client\Configuration\Client Properties")).$("Local SMS Path")
.\SCToastNotification.exe "Notice: Pending Reboot Needed" "Your PC Needs to restart as soon as you can."
msg * "Notice: Pending Reboot Needed...." "Your PC Needs to restart as soon as you can."
When i connected and click "Notify-UserOfReboot" the Client Center hangs. The client get no message!