Error while preparing to send sharing message (Outlook 2007/2010/2013/2016)

I got the following error when I had migrated a customer from a Small Business Server to our local Hosted Exchange.

Outlook on a domain looks to Active Directory to get the auto discover information. If you run the Outlook connectivity tester on the affected computer, you will see that it returns the local SBS server autodiscover settings, even if you have configured Outlook to use an external provider.

The simplest way to fix this if the SBS server is still in used and Exchange is still installed, is to run the following commands:

Get-ClientAccessServer | Set-ClientAccessServer -AutoDiscoverServiceInternalUri https://mail.externaldomain.com/Autodiscover/Autodiscover.xml

And

get-autodiscovervirtualdirectory | Set-AutodiscoverVirtualDirectory -ExternalUrl https://mail.externaldomain.com/Autodiscover/Autodiscover.xml -InternalUrl https://mail.externaldomain.com/Autodiscover/Autodiscover.xml

This then points the Outlook client to the correct external Autodiscover service.

If you have any questions, please let me know.

3 thoughts on “Error while preparing to send sharing message (Outlook 2007/2010/2013/2016)”

  1. Hi
    I have been looking for a solution to this problem. We don’t have an SBS server but we do have a 2008DC and Exch 2010 servers. We moved to exch 2010 back in October last year. Our environment and user’s sophistication/usage is minimal. just last week someone tried to share a calendar and got that error. Can you explain the powershell commands? what does the get/set combo do?

    1. Hi. Get / Set grabs the current autodiscover directory and then sets it to your external facing URL. This is mainly for Office 365 customers who migrate, but still have an Exchange server in-house. Outlook will use the autodiscover url internally to locate the exchange server… You don’t want this. So if you set your Exchange server to point to Office 365, this fixes the issue. Hope that makes sense?

Leave a Reply