Skip to content

Tag: Flow

Salesforce Flow: Fixing Formatting and Rendering Issues in Emails with Rich-Text Templates

When using the Send Email core action in Salesforce Flow to send an email with a rich-text body. Switching between plain text and rich text in the template editor alters the HTML markup, resulting in incorrect rendering and formatting issues.

To avoid this, use a plain text template with HTML markup and select Rich-Text-Formatted Body as true in the Send Email action. This approach ensures the email body is formatted correctly. See the attached screenshots for reference.

Advanced Send Email Flow Action – Send email from Salesforce flow with CC, BCC, and email attachments

This class can be used in flows to send emails programmatically without needing predefined email alerts.
It allows customization of email content, recipients, and attachments on the fly. The Apex class is designed to send emails from Salesforce without the need for an Email Alert.

Screen Flow – Preview the email body with merge fields populated before sending out

This article shows, how to preview an email in a screen flow with actual merge fields populated before sending it out to a customer, ensuring all details are correct. By using an Apex invocable action that returns email body with all the merge fields populated and in the screen flow show text using display text component and HTML body using an LWC.

Complex Validation Rule using Salesforce Record Trigger Flows Instead of using Apex code

This article walks you through creating a validation rule using a record trigger flow instead of using apex code for complex business requirements. Sometimes we have requirements that can not be accomplished using standard validation rules. So you can use this approach instead of developing before insert apex trigger.

This articles covers a business requirement that before an opportunity is marked as closed won, the opportunity must have at least one contact role.