This article explains how to create a Salesforce Process Builder process that fires on EmailMessage record creation and automatically generates a Task.
Note: Process Builder is being retired — new automations should be built in Salesforce Flow. The EmailMessage object stores email addresses as plain string fields (ToAddress, CcAddress, FromAddress) rather than as lookup relationship fields, which is why it is not possible to automatically link the generated Task to the sending or receiving Contact, Lead, or User record.
1. Go to Setup.
2. Enter Process Builder in the Quick Find box.
3. In Process Builder, click New.
4. Input Process Name and let API Name auto-populate.
5. Optionally, input Description.
6. Select “A record changes” for the process starts when.
7. Click Save.
8. Click Add Object.
9. On the Object field, type in “Email Message”
10. Click Save.
12. Click Add Criteria.
13. Input the necessary details i.e. Criteria Name, Criteria for Executing Actions, and Conditions.
14. After it is done, click Save.
15. Click Add Action under Immediate Actions.
16. Select Create a Record.
17. Input Action Name.
18. Type in “Task” for the Record Type.
19. Input the necessary field values.
20. After it is done, click Save.
21. Verify the details and then click Activate.
Limitation: Relating Tasks to Email Senders and Recipients:
Because the email addresses in the EmailMessage object are stored as string fields (ToAddress, CcAddress, FromAddress), it is not possible to automatically resolve these to Salesforce Contact, Lead, or User record IDs within Process Builder. As a result, the WhoId (Contact/Lead relationship) on the created Task cannot be set to the actual sender or recipient.
Alternative: Use Salesforce Flow Instead:
Salesforce Workflow Rules & Process Builder End of Support
Salesforce Flow
000383310

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.