Hello,
I have the following script that Monitors the Windows Service and outputs on a webpage whether the service is running or not. I would like it to display as green if running and red if stopped or disabled. Any idea how I can achieve this? Thanks!
$Var1 = get-service WindowsService1, WindowsService2, WindowsService3, WindowsService4 -ComputerName Service1,Service2 | ConvertTo-Html -Property Name, Status, MachineName| format-table Name,Status,Machinename -autosize
$Var1 | Out-File C:\Script\Services.html