Get-​Msol​Administrative​Unit​Member

Gets members of an administrative unit.

Syntax

Get-MsolAdministrativeUnitMember
   [-AdministrativeUnitObjectId <Guid>]
   [-MaxResults <Int32>]
   [-TenantId <Guid>]
   [<CommonParameters>]
Get-MsolAdministrativeUnitMember
   [-AdministrativeUnitObjectId <Guid>]
   [-TenantId <Guid>]
   [-All]
   [<CommonParameters>]

Description

The Get-MsolAdministrativeUnitMember cmdlet gets members of an administrative unit.

Examples

Example 1: Get members of an administrative unit

PS C:\> $AdminstrativeUnit = Get-MsolAdministrativeUnit -SearchString "West Coast"
PS C:\> Get-MsolAdministrativeUnitMember -AdministrativeUnitObjectId $AdminstrativeUnit.ObjectId

The first command gets an administrative unit that matches a search string by using the Get-MsolAdministrativeUnit cmdlet. The command stores the administrative unit in the $AdminstrativeUnit variable.

The second command returns all members of the administrative unit in $AdminstrativeUnit.

Required Parameters

-All

Indicates that this cmdlet returns all results that it finds. Do not specify this parameter and the MaxResults parameter.

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Optional Parameters

-AdministrativeUnitObjectId

Specifies the unique object ID of the administrative unit on which this cmdlet operates.

Type:Guid
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-MaxResults

Specifies the maximum number of results that this cmdlet returns.

Type:Int32
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-TenantId

Specifies the unique ID of the tenant on which to perform the operation. The default value is the tenant of the current user. This parameter applies only to partner users.

Type:Guid
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Outputs

Microsoft.Online.Administration.AdministrativeUnitMember

This this cmdlet returns objects that contain the following:

  • DisplayName. The display name of the administrative unit member.
  • EmailAddress. The user principal name of the administrative unit member.
  • ObjectId. The unique ID of the administrative unit member.