Pages

Saturday, March 11, 2017

How to use PowerShell to Change the Email Address of Office 365 Groups

One of the odd things about Office 365 is how much you have to resort to PowerShell to get things done. That's currently the case with the Office365 Groups, a recently introduced type of group that works particularly well across all of the Office365 applications.

I've been setting a few things up with Office365 groups lately and I've had two instances where I needed to do some renames. Once was when the people who asked for the group changed their mind about the name and the other was when I wanted to rebuild an existing sharepoint site (and reuse the name).

In both cases, I was able to change the name but the email address itself was greyed out.

The Solution is to use PowerShell

Start Powershell by clicking Start and typing PowerShell, then Right-click on the icon and run as Administrator.

In the console that appears, type;

Set-ExecutionPolicy RemoteSigned

This elevates some privileges. You'll need to choose Y and press enter.

So, in our case, we want to change InformationTechnology1@mycompany.com.au to InformationTechnology@mycompany.com.au. The group name is Information Technology. This means that the command to use would be;

That's it. If you switch back to the admin screen and refresh, you'll see that the group now has the correct email address.

If you want to change more groups, you can simply run that last command line again with different parameters (all the earlier lines were just set up lines). If you've finished, you can simply close PowerShell.