Status - property in ROOT\MicrosoftIISv2 namespace

Status in other namespaces

List of classes with Status local property in ROOT\MicrosoftIISv2 namespace

propertyClassOrigin
StatusCIM_ManagedSystemElementCIM_ManagedSystemElement

List of classes with Status derived property in ROOT\MicrosoftIISv2 namespace

propertyClassOrigin
StatusCIM_ApplicationSystemCIM_ManagedSystemElement
StatusCIM_LogicalElementCIM_ManagedSystemElement
StatusCIM_ServiceCIM_ManagedSystemElement
StatusCIM_SystemCIM_ManagedSystemElement
StatusIIsACECIM_ManagedSystemElement
StatusIIsAdminACLCIM_ManagedSystemElement
StatusIIsApplicationPoolCIM_ManagedSystemElement
StatusIIsApplicationPoolsCIM_ManagedSystemElement
StatusIIsCertMapperCIM_ManagedSystemElement
StatusIIsCompressionSchemeCIM_ManagedSystemElement
StatusIIsCompressionSchemesCIM_ManagedSystemElement
StatusIIsComputerCIM_ManagedSystemElement
StatusIIsCustomLogModuleCIM_ManagedSystemElement
StatusIIsDirectoryCIM_ManagedSystemElement
StatusIIsFilterCIM_ManagedSystemElement
StatusIIsFiltersCIM_ManagedSystemElement
StatusIIsFtpInfoCIM_ManagedSystemElement
StatusIIsFtpServerCIM_ManagedSystemElement
StatusIIsFtpServiceCIM_ManagedSystemElement
StatusIIsFtpVirtualDirCIM_ManagedSystemElement
StatusIIsImapInfoCIM_ManagedSystemElement
StatusIIsImapRoutingSourceCIM_ManagedSystemElement
StatusIIsImapServerCIM_ManagedSystemElement
StatusIIsImapServiceCIM_ManagedSystemElement
StatusIIsImapSessionsCIM_ManagedSystemElement
StatusIIsImapVirtualDirCIM_ManagedSystemElement
StatusIIsLogModuleCIM_ManagedSystemElement
StatusIIsLogModulesCIM_ManagedSystemElement
StatusIIsMimeMapCIM_ManagedSystemElement
StatusIIsNntpExpirationCIM_ManagedSystemElement
StatusIIsNntpExpireCIM_ManagedSystemElement
StatusIIsNntpFeedCIM_ManagedSystemElement
StatusIIsNntpFeedsCIM_ManagedSystemElement
StatusIIsNntpGroupsCIM_ManagedSystemElement
StatusIIsNntpInfoCIM_ManagedSystemElement
StatusIIsNntpRebuildCIM_ManagedSystemElement
StatusIIsNntpServerCIM_ManagedSystemElement
StatusIIsNntpServiceCIM_ManagedSystemElement
StatusIIsNntpSessionsCIM_ManagedSystemElement
StatusIIsNntpVirtualDirCIM_ManagedSystemElement
StatusIIsObjectCIM_ManagedSystemElement
StatusIIsPop3InfoCIM_ManagedSystemElement
StatusIIsPop3RoutingSourceCIM_ManagedSystemElement
StatusIIsPop3ServerCIM_ManagedSystemElement
StatusIIsPop3ServiceCIM_ManagedSystemElement
StatusIIsPop3SessionsCIM_ManagedSystemElement
StatusIIsPop3VirtualDirCIM_ManagedSystemElement
StatusIIsSmtpAliasCIM_ManagedSystemElement
StatusIIsSmtpDLCIM_ManagedSystemElement
StatusIIsSmtpDomainCIM_ManagedSystemElement
StatusIIsSmtpInfoCIM_ManagedSystemElement
StatusIIsSmtpRoutingSourceCIM_ManagedSystemElement
StatusIIsSmtpServerCIM_ManagedSystemElement
StatusIIsSmtpServiceCIM_ManagedSystemElement
StatusIIsSmtpSessionsCIM_ManagedSystemElement
StatusIIsSmtpUserCIM_ManagedSystemElement
StatusIIsSmtpVirtualDirCIM_ManagedSystemElement
StatusIIsUserDefinedLogicalElementCIM_ManagedSystemElement
StatusIIsWebDirectoryCIM_ManagedSystemElement
StatusIIsWebFileCIM_ManagedSystemElement
StatusIIsWebInfoCIM_ManagedSystemElement
StatusIIsWebServerCIM_ManagedSystemElement
StatusIIsWebServiceCIM_ManagedSystemElement
StatusIIsWebVirtualDirCIM_ManagedSystemElement
StatusWin32_BaseServiceCIM_ManagedSystemElement
StatusWin32_ServiceCIM_ManagedSystemElement

Code samples for Status property

Get instance of WMI class using GetObject, Status property of Win32_Service

Short VBS code - get a single specified instance of Win32_Service class or get a default unnamed instance (singleton) of the class, using one single command GetObject with exact path of the wmi object.

'https://wutils.com/wmi/
Dim wmiObject
Set wmiObject = GetObject( _
 "WINMGMTS:\\.\ROOT\MicrosoftIISv2:" + _
 "Win32_Service.Name=""adfssrv""")
Wscript.Echo wmiObject.Status 'or other property name, see properties
See more VBS samples of Win32_Service class

WMI query - sample windows WQL with C#, Status property of Win32_Service

Get a specified instance of Win32_Service by a key, get a default unnamed instance (singleton) of the class or list instances of the class by wmi query using this c# sample code.
See in another language: VBScript, VB.Net.
//https://wutils.com/wmi/

//Project -> Add reference -> System.Management
//using System.Management;

//create a management scope object
ManagementScope scope = new ManagementScope("\\\\.\\ROOT\\MicrosoftIISv2");

//create object query
ObjectQuery query = new ObjectQuery("SELECT * FROM Win32_Service Where Name=\"adfssrv\"");

//create object searcher
ManagementObjectSearcher searcher =
                        new ManagementObjectSearcher(scope, query);

//get a collection of WMI objects
ManagementObjectCollection queryCollection = searcher.Get();

//enumerate the collection.
foreach (ManagementObject m in queryCollection) 
{
  // access properties of the WMI object
  Console.WriteLine("Status : {0}", m["Status"]);
  
}

WMI query - sample windows WQL with VB.Net, Status property of Win32_Service

Get a specified instance of Win32_Service by a key, get a default unnamed instance (singleton) of the class or list instances of the class by wmi query using this VB.Net sample code.
See in another language: VBScript, C#
'Project -> Add reference -> System.Management
'Imports System.Management

'Get the namespace management scope
Dim Scope As New ManagementScope("\\.\ROOT\MicrosoftIISv2")

'Get a result of WML query 
Dim Query As New ObjectQuery("SELECT * FROM Win32_Service Where Name="adfssrv"")

'Create object searcher
Dim Searcher As New ManagementObjectSearcher(Scope, Query)

'Get a collection of WMI objects
Dim queryCollection As ManagementObjectCollection = Searcher.Get

'Enumerate wmi object 
For Each mObject As ManagementObject In queryCollection
  'write out some property value
  Console.WriteLine("Status : {0}", mObject("Status"))
Next
comments powered by Disqus
WUtils.com