[SalesForce] Adding a Button to the Send an Email page

I was wondering if it is at all possible to create a new Send button (in this case Send Secure Email button) on the Send an Email page itself. This button would utilize our REST APIs in order to send the message securely after the user writes their message. I know that you can add buttons to the Activity Screens like the ones below:
enter image description here

However this was not the desirable approach as these are not attached to the Send an Email "Task" page itself, but rather the activity screens before it. For visual clarification I am basically looking to do the following:
enter image description here

Any advice/help would be greatly appreciated as I am stumped on how to do this.

Best Answer

There is a way to send emails from a button. I don't know if this is the best option or exactly what you need but I can send emails by adding a button in the object I need to send the email from just by using this url:

/_ui/core/email/author/EmailAuthor?rtype=003&p3_lkid={!Case.Id}&retURL=%2F{!Case.Id}&p5={!$User.Email}&p24="AdditionalEmailAddresGoesHere&template_id=00X58000000sJE3

This is for the Case object but you can use it for the Task as well.

  1. Got to Set up
  2. Build
  3. Activities -> Task Buttons, Links and Actions
  4. Click in New Button or Link
  5. Insert label name, select Detail Page Button
  6. Behavior = Display in a new window
  7. Content Source = URL
  8. Insert this:

/_ui/core/email/author/EmailAuthor?rtype=003&p3_lkid={!Task.Id}&retURL=%2F{!Task.Id}&p5={!$User.Email}&p24="AdditionalEmailToSend&template_id=00X58000000sJE3

The last part of this link needs to point out to the email template you want to use for your email, so change the "template_id=00X58000000sJE3" to your template id. If you want to use this link in another button for another object you can do that by changing the parts in which you see "Task" for the object you want to use. I have tested this on the case and opportunity objects and works fine.

Let me know if it is also working for you.

Don't forget to add you new button to your custom button section in the pages you need to.

Good luck and let us know the outcome.

Related Topic