WindowsIdentity.IsSystem 属性
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
获取一个值,该值指示系统是否将用户帐户标识为 System 帐户。
public:
virtual property bool IsSystem { bool get(); };
public virtual bool IsSystem { get; }
member this.IsSystem : bool
Public Overridable ReadOnly Property IsSystem As Boolean
属性值
如果用户帐户是 System 帐户,则为 true
;否则为 false
。
示例
下面的代码演示 IsSystem 如何使用属性返回一个值,该值指示系统是否将用户帐户标识为 System 帐户。 此代码示例是为类提供的更大示例的一部分 WindowsIdentity 。
if ( windowsIdentity->IsSystem )
{
propertyDescription = String::Concat( propertyDescription, ", is a System account" );
}
if (windowsIdentity.IsSystem)
{
propertyDescription += ", is a System account";
}
If (windowsIdentity.IsSystem) Then
propertyDescription += ", is a System account"
End If