Deploy Outlook mail profile settings via GPO or script

This guide provides a script which you can use to deploy mail profile account settings contained in a prf-file. This script can be used as a (Group Policy) logon script and also checks if the mail profile already exists or not.