Force kill a service and restart it with powershell in a batch script
Just replace the TermService and ‘Remote Desktop Services’ with the service name you wish to force kill and restart it. [shell] FOR /F “tokens=3” %%A IN (‘sc queryex TermService ^| findstr PID’) DO (SET pid=%%A) taskkill /F /PID %pid% sleep...