How to export Office 365 group members using PowerShell
The following is a comparison between exporting Office 365 group members with Windows PowerShell and ADManager Plus:
Steps to get a list of Office 365 group members using PowerShell:
- Identify the Office 365 tenant from which you want to retrieve the report.
- Identify the PowerShell cmdlet you need to fetch the report.
- Compile the script.
- Execute it in Windows PowerShell.
- The report will be exported in the given format.
- To obtain the report in a different format, modify the script according to the needs of the user.
Sample Windows PowerShell script:
Click to copy entire script
Get-UnifiedGroup -ResultSize Unlimited | Select DisplayName,GroupType,PrimarySmtpAddress
Steps to get the report using ADManager Plus:
- Click Office 365 -> Group Reports -> Group Members.
- Select the desired Office 365 account and groups.
- Click Generate and export the report in any of the preferred formats.
» Start 30-day Free Trial
Following are the limitations to obtain Office 365 groups members using native tools like Windows PowerShell:
- Adding even minor details to the report—such as adding additional attributes—require scripts to be modified and executed again, which is time consuming.
- Exporting a report in a specific format requires a script to be modified accordingly, which increases the complexity of the scripts.
- Troubleshooting is not easy in case of errors.
ADManager Plus can retrieve Office 365 group members in CSV, PDF, HTML, or XLSX format in a simple and intuitively designed UI.