PowerShell: Kill a Windows Service Forcefully
# killService.ps1 $serviceName='vmms' function killService($serviceName='Spooler',$restart=$false){ $processId=Get-WmiObject -Class Win32_Service -Filter "Name LIKE '$serviceName'"|Select-Object -ExpandProperty ProcessId if($processId.count…
0 Comments