Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

WindowsPrincipal.IsInRole Method

Determines whether the current principal belongs to a specified Windows user group.

Name Description
WindowsPrincipal.IsInRole (Int32) Determines whether the current principal belongs to the Windows user group with the specified relative identifier (RID).
WindowsPrincipal.IsInRole (SecurityIdentifier) Determines whether the current principal belongs to the Windows user group with the specified security identifier (SID).
WindowsPrincipal.IsInRole (String) Determines whether the current principal belongs to the Windows user group with the specified name.
WindowsPrincipal.IsInRole (WindowsBuiltInRole) Determines whether the current principal belongs to the Windows user group with the specified WindowsBuiltInRole.

There are four overloads for this method. For performance reasons, the IsInRole(SecurityIdentifier) overload is strongly recommended.

NoteImportant:

The IsInRole method is not supported on Windows 98 or Windows Millennium Edition.

Community Additions

Show:
© 2017 Microsoft