TL;DR
Is there a way via script, powershell, reg delete, via telekinesis, whatever to reset Outlook 2013 as if no profiles ever existed and it was running for the first time ever?
Still working through this one but hoping others have insight.
SCENARIO
Lots of users here have existing Outlook profiles connecting to an on-premise Exchange server. We are in the middle of our migration to Office 365. In order to migrate the user's Outlook you have to either create a new profile in Outlook or delete the old profile completely and then "start fresh".
We want our users to start fresh and have the default profile name of "Outlook" for their mail profile (instead of something custom or a 2nd profile like "O365"). This is because our ERP system looks for this profile to send email while in the ERP software.
PROBLEM
The problem is "starting fresh" isn't really starting fresh.
If I manually remove the default profile "Outlook" from the Mail
control panel settings, then Outlook starts up without a profile but prompts for a profile name:
If I type Outlook
as the new Profile name now I get:
If I go into REGEDIT
and look in:
HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows Messaging Subsystem\Profiles
I still see "Outlook" as a profile.
I tried doing a Reg DELETE
of this key and all sub-keys and while it says "successfully deleted" it doesn't.
If I manually delete this profile key I can then start Outlook again and when it prompts for a new Profile name I can put in Outlook
and it will take it and let me continue as if it is a new setup of Outlook:
It doesn't appear from the command line switches for Outlook 2013 (found here) that the /cleanprofile is still around.
BOTTOM LINE QUESTION
Is there a way via script, powershell, reg delete, via telekinesis, whatever to reset Outlook 2013 as if no profiles ever existed and it was running for the first time ever?
This will delete the default profile called Outlook, and then recreate it with no settings. Then when you re-run Outlook, it will launch the wizard.
Reset the key under
HKEY_CURRENT_USER\Software\Microsoft\Office\15.0\Outlook\
for first run from False to True.According to the command-line switches page on MSDN you should be able to start outlook with a command-line argument to make it act like it's the first run. Give this a try and let me know how it works for you:
Source: https://office.microsoft.com/en-us/outlook-help/command-line-switches-HP001003110.aspx
You are on the right track.
You will have to delete that Profiles key the registry.
But, and here is the catch, that can only be done by
reg delete
if there is nothing running (in foreground or background) that touches these keys.So you will have to make absolutely sure that outlook.exe is not running. (It often keeps hanging around in the background for another 2-3 minutes after you close it.)
Also the ERP application itself may keep these keys locked. And if you run some sort of key-chain or certification software (e.g. PGP) that may interface with these reg-keys too.
If you want to script this make sure you run it as the real user. Not another admin-account. After all it is "HKLM\Currrent User*" we are talking about here.
I have done this before on Office 2007 and 2010 (which should be identical in this regard).
We put the delete command in the domain login-script with some additional checks to only run this once and only if the user was not migrated YET.