{"id":727,"date":"2014-09-24T11:59:02","date_gmt":"2014-09-24T11:59:02","guid":{"rendered":"http:\/\/www.greytrix.com\/blogs\/salesforce\/?p=727"},"modified":"2025-05-30T04:41:45","modified_gmt":"2025-05-30T04:41:45","slug":"send-email-from-apex","status":"publish","type":"post","link":"https:\/\/www.greytrix.com\/blogs\/salesforce\/2014\/09\/24\/send-email-from-apex\/","title":{"rendered":"Send email from Apex | Salesforce"},"content":{"rendered":"\n<p>Once we had a requirement wherein we wanted to send an email and the content of that email was from multiple objects. Here is the code snippet that we can use for sending email from Apex code using Single Email.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><a href=\"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-content\/uploads\/2014\/09\/email-code.jpg\"><img decoding=\"async\" src=\"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-content\/uploads\/2014\/09\/email-code.jpg\" alt=\"email code\" class=\"wp-image-729\"\/><\/a><\/figure><\/div>\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><a href=\"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-content\/uploads\/2014\/09\/send-email.jpg\"><img decoding=\"async\" src=\"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-content\/uploads\/2014\/09\/send-email.jpg\" alt=\"send email\" class=\"wp-image-730\"\/><\/a><\/figure><\/div>\n\n\n<p>There is however a limitation in using Single Email functionality, you can send only 1,000 emails per 24 hours.<\/p>\n\n\n\n<p><span style=\"font-size: Medium;\"><strong>About Us<\/strong><\/span><br><a href=\"https:\/\/www.greytrix.com\/\">Greytrix<\/a> as a Salesforce Product development partner offers a wide variety of integration products and services to the end users as well as to the Partners across the globe. We offers Consultation, Configuration, Training and support services in out-of-the-box functionality as well as customizations to incorporate custom business rules and functionalities that requires apex code incorporation into the Salesforce platform.<\/p>\n\n\n\n<p><a href=\"https:\/\/www.greytrix.com\/\">Greytrix<\/a> has some unique solutions for Cloud CRM such as Salesforce integration with <a href=\"https:\/\/www.greytrix.com\/product\/sage-x3\/gumu-x3-salesforce-integration\">Sage Enterprise Management (Sage X3<\/a>), Sage Intacct, <a href=\"https:\/\/www.greytrix.com\/product\/sage-100-erp\/gumu-100-salesforce-integration\">Sage 100 <\/a>and <a href=\"https:\/\/www.greytrix.com\/product\/sage-300-erp\/gumu-300-salesforce-integration\">Sage 300 (Sage Accpac)<\/a>. We also offer best-in-class Cloud CRM <a href=\"https:\/\/www.greytrix.com\/product\/crm-development\/salesforce-com\">Salesforce customization and development services<\/a> along with services such as Salesforce <a href=\"https:\/\/www.greytrix.com\/product\/professional-services\/data-migration-services\">Data Migration<\/a>, <a href=\"https:\/\/www.greytrix.com\/product\/professional-services\/integrated-application-development\">Integrated App development<\/a>, <a href=\"https:\/\/www.greytrix.com\/product\/professional-services\/custom-development\">Custom App development<\/a> and <a href=\"https:\/\/www.greytrix.com\/product\/professional-services\/maintenance-support\">Technical Support<\/a> to business partners and end users.<\/p>\n\n\n\n<p>Greytrix GUMU&#x2122; integration for Sage ERP \u2013 Salesforce is a 5-star app listed on <a href=\"https:\/\/appexchange.salesforce.com\/listingDetail?listingId=a0N30000000psM5EAI\" target=\"_blank\" rel=\"noopener\">Salesforce AppExchange<\/a>.<\/p>\n\n\n\n<p>For more information, please contact us at <a href=\"mailto:salesforce@greytrix.com\">salesforce@greytrix.com<\/a>. We will be glad to assist you.<\/p>\n\n\n\n<p><strong><span style=\"font-size: Medium;\">Related Posts<\/span><\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a title=\"Consuming External Web Service in Apex\" href=\"http:\/\/www.greytrix.com\/blogs\/salesforce\/2014\/09\/24\/consuming-external-web-service-in-apex\/\" target=\"_blank\" rel=\"noopener\">Consuming External Web Service in Apex<\/a><\/li>\n\n\n\n<li><a title=\"Create Button for List View\" href=\"http:\/\/www.greytrix.com\/blogs\/salesforce\/2014\/09\/24\/create-button-for-list-view\/\" target=\"_blank\" rel=\"noopener\">Create Button for List View&nbsp;<\/a><\/li>\n\n\n\n<li><a title=\"Request updated information from Salesforce contacts\" href=\"http:\/\/www.greytrix.com\/blogs\/salesforce\/2014\/08\/30\/request-updated-information-from-salesforce-contacts\/\" target=\"_blank\" rel=\"noopener\">Request updated information from Salesforce contacts<\/a><\/li>\n\n\n\n<li><a title=\"Quickly add fields to Existing Object without using standard wizard\" href=\"http:\/\/www.greytrix.com\/blogs\/salesforce\/2014\/08\/26\/quickly-add-fields-to-existing-object-without-using-standard-wizard\/\" target=\"_blank\" rel=\"noopener\">Quickly add fields to Existing Object without using standard wizard<\/a><\/li>\n\n\n\n<li><a title=\"Mass Transfer Custom Object Records from One User to Another\" href=\"http:\/\/www.greytrix.com\/blogs\/salesforce\/2014\/08\/26\/mass-transfer-custom-object-records-from-one-user-to-another\/\" target=\"_blank\" rel=\"noopener\">Mass Transfer Custom Object Records from One User to Another<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Once we had a requirement wherein we wanted to send an email and the content of that email was from multiple objects. Here is the code snippet that we can use for sending email from Apex code using Single Email. There is however a limitation in using Single Email functionality, you can send only 1,000\u2026 <span class=\"read-more\"><a href=\"https:\/\/www.greytrix.com\/blogs\/salesforce\/2014\/09\/24\/send-email-from-apex\/\">Read More &raquo;<\/a><\/span><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[13,596,107,595],"class_list":["post-727","post","type-post","status-publish","format-standard","hentry","category-salesforce-srv","tag-apex","tag-apex-code-using-single-email","tag-email","tag-send-email-from-apex"],"_links":{"self":[{"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/posts\/727","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/comments?post=727"}],"version-history":[{"count":3,"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/posts\/727\/revisions"}],"predecessor-version":[{"id":10846,"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/posts\/727\/revisions\/10846"}],"wp:attachment":[{"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/media?parent=727"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/categories?post=727"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/salesforce\/wp-json\/wp\/v2\/tags?post=727"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}