The Salesforce Outlook Integration lets users create email messages and Tasks directly from Outlook. When Outlook Integration shows the error "An unexpected error occurred" while sending an email, it usually means something in Salesforce is blocking the creation or deletion of the related Task or Email Message record.
Common causes include Flows, Apex triggers, validation rules, or custom code that conflict with Task or Email Message creation. This article explains how to gather diagnostic information and identify what is interfering with Outlook Integration.
This article explains how to troubleshoot the "An unexpected error occurred" message in Salesforce Outlook Integration when a user tries to send an email, by reviewing browser console logs and Salesforce debug logs to find what is blocking the underlying Task or Email Message record.
Outlook Integration needs to be able to create Email Message and Task records in Salesforce. If a Flow, Apex trigger, validation rule, or custom code fires when that record is created or deleted and throws an error, Outlook Integration surfaces it as "An unexpected error occurred." For example, a validation rule that requires a specific Task field to be populated can block the Task Outlook Integration tries to create automatically.
For steps to capture console logs from Outlook Integration on Mac OS, see Get Console Logs for Outlook Integration on Mac OS.
While reproducing the error, review Salesforce Debug Logs and check whether any Flows, Apex triggers, validation rules, or custom code run against the Task or EmailMessage object at that time. Temporarily deactivating a suspect automation and retesting can help confirm the root cause.
004518958

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.