Returns information about the current state of a computer running Microsoft Exchange Server 2003
On Error Resume NextstrComputer = "."Set objWMIService = GetObject("winmgmts:" _& "{impersonationLevel=impersonate}!\\" & _strComputer & "\CIMV2\Applications\Exchange")Set colItems = objWMIService.ExecQuery _("Select * from ExchangeServerState")For Each objItem in colItemsWscript.Echo "Cluster state: " & objItem.ClusterStateWscript.Echo "Cluster state string: " & _objItem.ClusterStateStringWscript.Echo "CPU state: " & objItem.CPUStateWscript.Echo "CPU state string: " & objItem.CPUStateStringWscript.Echo "Disks state: " & objItem.DisksStateWscript.Echo "Diskss state string: " & objItem.DisksStateStringWscript.Echo "Distinguished name: " & objItem.DNWscript.Echo "Group dsitinguihsed name: " & objItem.GroupDNWscript.Echo "Group GUID: " & objItem.GroupGUIDWscript.Echo "GUID: " & objItem.GUIDWscript.Echo "Memory state: " & objItem.MemoryStateWscript.Echo "Memory state string: " & _objItem.MemoryStateStringWscript.Echo "Name: " & objItem.NameWscript.Echo "Queues state: " & objItem.QueuesStateWscript.Echo "Queues state string: " & _objItem.QueuesStateStringWscript.Echo "Server maintenance: " & _objItem.ServerMaintenanceWscript.Echo "Server state: " & objItem.ServerStateWscript.Echo "Server state string: " & _objItem.ServerStateStringWscript.Echo "Services state: " & objItem.ServicesStateWscript.Echo "Services state string: " & _objItem.ServicesStateStringWscript.Echo "Unreachable: " & objItem.UnreachableWscript.Echo "Version: " & objItem.VersionWscript.EchoNext
This is a VB Script, this can be used by saving the file in .vbs file