Forum Discussion
Gianni88
Nov 20, 2019Copper Contributor
PowerShell command to export user's manager name
Dear all, I would like to know what is the powershell command to get this information : First Name Last Name Email address JobTitle Manager report Name ...
- Dec 03, 2019
Hi Gianni88
it is normal you can't find the Manager field.
The foreach make the work for you, expanding manager property π
Please, debug your scripts in ISE or using output messages π
Cheers,Federico
Nov 30, 2019
Gianni88
Dec 02, 2019Copper Contributor
Hi Federico,
As we use MFA (Multa Factor Authentification), I am not able to get into Powershell. I tried to follow this link (without success) : https://docs.microsoft.com/en-us/powershell/exchange/office-365-scc/connect-to-scc-powershell/mfa-connect-to-scc-powershell?view=exchange-ps
Do you know which command I need to run to connect to Powershell Azure (with MFA) ?
Thanks.
Gianni
- Dec 02, 2019
Hi Gianni88 ,
ok it's easy π
You need to use just
Connect-AzureAD
instead of
$AzureAdCred = Get-Credential Connect-AzureAD -Credential $AzureAdCred
the second part of the script it's the same π
Cheers,
Federico
- Gianni88Dec 03, 2019Copper Contributor
Hi Federico,
Thanks, step by step we move forward, I am in now π
When I run the ps1 file, it does not display anything (look at the attachment).
What I am doing wrong ?
Thanks.
- Dec 03, 2019
Hi Gianni88 ,
try to run
> $users = Get-AzureADUser -All $true > $users
after connect π
Are there users in $users?Cheers,
Federico