Activity › Forums › Salesforce® Discussions › What is mail.setHTMLBody() in Salesforce? Salesforce® Discussions What is mail.setHTMLBody() in Salesforce? Posted by Aditya on May 11, 2020 at 4:21 PM What is mail.setHTMLBody() in Salesforce? Deepak replied 6 years ago 2 Members · 1 Reply 1 Reply Deepak Member May 12, 2020 at 5:41 AM It is HTML version of the email, specified by the sender. The value is encoded according to the specification associated with the organization. Specify a value for setTemplateId, setHtmlBody, or setPlainTextBody. Log In to reply. Public All Members My Connections Only Me PublicAll MembersMy ConnectionsOnly Me Public All Members My Connections Only Me