After I migrated my company’s email off of Communigate (seriously, who names their company Stalker?) onto Exchange Online I needed to do a lot of cleanup using Powershell. We’ve also got compatibility with Outlook 2010 to worry about which has created some issues. Below is a link to my auto-login script.

Note: Credentials are saved using DPAPI, so are secure but likely break compliance with other company security policies

Enter-ExchangeSession