Office365 User profiles

Copper Contributor

Hey Guys,

 

How can check who tenant  admin is?

I am trying to edit user profile using default form, Somehow it works for few and doesnot work for other users. What can be the reason behind this?

 

It does not save when i click on "Save and Close"

3 Replies

As workaround you can use powershell with Msonline module for the query. Download and install the appropriate Msonline PS module and its prerequirements. Connect to MSonline then query Get-Msolrole. Copy the ObjectId of the Company Administrator. Then Get-Msolrolemember -Roleobject "copied ObjectID of the Company Administrator". The result will show all tenant Admins.

You can also use this Powershell script to get the list of all Tenant Admins and its Role.

 

Get-MsolRole | %{$role = $_.name; Get-MsolRoleMember -RoleObjectId $_.objectid} | select @{Name="Role"; Expression = {$role}}, DisplayName, EmailAddress

And if you use the Azure AD V2 module, the code is:

 

Get-AzureADDirectoryRole | %{$Role = $_.DisplayName; Get-AzureADDirectoryRoleMember -ObjectId $_.ObjectId} | Format-Table @{Name="Role"; Expression = {$Role}}, DisplayName, UserPrincipalName -AutoSize