' List Tabular Output in a Command Window


Set objWMIService = GetObject("winmgmts:" _
    & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")

Set colServices = objWMIService.ExecQuery("Select * from Win32_Service")

For Each objService in colServices
    intPadding = 50 - Len(objService.DisplayName)
    intPadding2 = 17 - Len(objService.StartMode)
    strDisplayName = objService.DisplayName & Space(intPadding)
    strStartMode = objService.StartMode & Space(intPadding2)
    Wscript.Echo strDisplayName & strStartMode & objService.State
Next
search for scripts

VbsEdit contains all these sample scripts!


Download Now!



Download   Home   Scripts

Copyright © 2001-2024 adersοft