Automatically restart computer when internet connection is lost
I have some trouble to do a script for Windows 10 that will check my internet connection every 2 minutes and restart the computer if it doesn’t find any connection. I tried with PowerShell: mainLoop() sleep 120 { if (!(Test-Connection 8.8.8.8 -Quiet)) { #Write-Host “Not connected” Restart-Computer } else { mainLoop() } } Do you have … Read more