Questions tagged [email-template]

Salesforce email templates come in a variety of shapes and sizes, ranging from Text to Visualforce. These email templates can be used through Salesforce through approval processes, workflows, etc to send email to users.

Filter by
Sorted by
Tagged with
0
votes
2answers
703 views

visualforce email template attaches with url hack but template not executed

Visual Force Code: (See bottom for URL Hack)Thanks <messaging:emailTemplate subject="Deal Approval Requested" recipientType="User" relatedToType="Contract_Assist__c"> <messaging:...
4
votes
1answer
8k views

email template security

Can we secure email templates to restrict usage within an organization? We have a couple of email templates that we want to make available to only a couple of people in the organization and wondering ...
2
votes
1answer
2k views

VisualForce Email template: how to disable the Link from the outputField (of type reference)

Is there anyway to disable the link from the apex:outputField when using it in an email template? Code: <apex:repeat value="{!relatedto.RTS_Items__r}" var="o"> <b>Product Code:</b&...
5
votes
2answers
3k views

Update Salesforce Community Url to custom login page

I have below default welcome email template which redirects the users to standard login page but it doesn't goes to my new custom community login page. Hi {!Receiving_User.FirstName}, Welcome to {!...
4
votes
3answers
3k views

Is it possible to send email to an arbitrary recipient using a VF Template?

I suspect the answer here is "No", but I thought I'd ask anyway. Can I send an email, using a VFTemplate, to an arbitrary email address, as opposed to a Contact, User, or Lead? I need to send a ...
4
votes
1answer
3k views

Email Template Replace merge field

I have an email template which uses merge fields from a custom object. For reasons difficult to explain here, I have to write my own code to read the body of the email template in Apex, replace merge ...
2
votes
1answer
895 views

Add campaign information into lead auto response email

I thought this would be an easy one but its not working as expected. I have a custom campaign type that has a "Meeting Time field" and i want to include that meeting time in an automatic email that ...
2
votes
0answers
54 views

Email template Preview shows lots of records even though its not related to anything

I just want to know how does the Email template review work. I have created a VF email template and added few VF components in it. The email template related to Custom Object,and in VF components, I ...
1
vote
1answer
1k views

Related custom object with Mass/Single EmailMessage

I need to write an apex method that send an email which is related to a custom object. The email will use a template which used merge fields from the custom object. How can I specify the custom object ...
3
votes
0answers
141 views

What is the order of assignment/autoassociate and auto response with web-to-lead?

I have a scenario, I need to auto associate new leads into campaigns, and send a customized email to them. The auto-assignment and the auto-association both work perfect. However, the HTML template I ...
2
votes
0answers
269 views

single sign on org and approval emails

The more and more I deal with SSO I am finding it requiring special care for existing OOB functionality. When we send out an approval email we send the link of the oppty record to the user and ask ...
2
votes
1answer
2k views

Dynamically displaying, adding, and deleting attachments from email template before sending email

-> A custom link on the contacts page invokes a VF page -> This VF page simulates the Send an Email page while auto populating a predefined email template: <apex:page standardController="contact" ...
2
votes
2answers
3k views

Prepopulating email attachments in one click using URL code

On Enterprise Edition: I have a custom link on the contact page layout that when clicked throws open a "Send an Email" edit page with several fields auto populated such as To, Subject, Email body, and ...
1
vote
1answer
2k views

Sending email with javascript on custom button

I am trying to select the appropriate email template using javascript on a custom button. Here is a stripped down version of my code: var template; var type = "{!My_Custom_Object__c.My_Field__c}"; ...
8
votes
1answer
6k views

Using a component to add attachments to visualforce email template and showing email link

We are trying to add attachments to an email template using a component. The code in the email template is: <messaging:emailTemplate subject="My Subject" recipientType="User" relatedToType="...
1
vote
0answers
120 views

How to Attach article related list corresponsing to mail subject in notification email when case is logged from email?

When case is logged from email, Notification email is received to the person who logged the case. This notification mail is sent to user with help of workflow which uses standard template. As per my ...
12
votes
4answers
12k views

How can Email Template be created in unit tests?

Can I create an Email Template as part of the unit test? If yes, how?
4
votes
3answers
6k views

How to Use the 'From' Address in Email Template like 'no-reply@my-domain name'

i created one custom template. once send the Template to my mail id using Send Test and Verfiy Merge Fields button. i get the from address like from:*Me mail Id*.but how can i impement no-reply@my ...
2
votes
1answer
1k views

how to prevent the system generated “Customer Portal: Customer Portal Reset Password (SAMPLE)” Email Template

i implemented the logic for generating Reset Password Custom Email Template for custom portal user in Apex. once the user reset the password from FrontEnd(PHP Form) using UserName now our code ...
4
votes
2answers
2k views

Recipient User Language email alert in workflow

How to get the recipient's language in a visualforce email? I'm trying to use this property: language="{!recipient.LanguageLocaleKey}" But when the email is sent, the recipient object is the ...
6
votes
1answer
2k views

Can you embed (not link) an image in an email template?

Is there any way to actually embed (not link to) an image in an email template in salesforce? What I have in mind would create an email with a 'Content-Type: text/html; charset="us-ascii"' in which it ...
1
vote
0answers
323 views

Ugly format of Email generated by EmailTemplate saved as Activity

I have written some code that sends an email based on an HTML based email template to contacts and stores a copy of the email as an activity. I noticed that the content of said email in the activity ...
8
votes
3answers
6k views

How to do email relaying in a safe way?

We want to use email relaying for our outgoing mails, to avoid email spoofing - aka sent via:1235434...@salesforce.com. From the official documentation I learned to use an unsecured SMTP server to do ...
2
votes
1answer
2k views

Scheduling a visualforce page as CSV

I am posting my approach, but still unable to send the VF page data as email attachment. scheuler + batch : global class Schedule_report implements Schedulable { global void execute(...
0
votes
1answer
729 views

How to receive the EmailTemplate Images in Email?

This is my custom text template code,i load the image in Documents and copy the image url and paste in src.But i didnt receive the images in my email ,just it shows text only........How to solve this? ...
2
votes
1answer
8k views

send email button from custom object

I am a newbie, and that's the probably reason why I am lost with this problem. I have two email templates created (one for students, and another for professorial). There is a custom object, and I need ...
1
vote
1answer
1k views

Custom Send Email Button With A “Hidden” Email Template

Anyone have an idea on how to have an Email Template in Salesforce which most Users "cannot see" but which they can use to send to clients? This would be done via a simple Custom Button: /email/...
13
votes
3answers
12k views

How to determine where an email template is being used?

We have some email templates in our email templates folder, but I'm not sure where they are being accessed or used. How do I investigate this? I looked into the emailTemplate table, but it didn't ...
0
votes
1answer
1k views

How to specify recipient name in text email to user?

Question How can I add the first name of a user email recipient to a text email template? Background I'm building an approval email template. The same template is used for various approvers which ...
3
votes
1answer
2k views

passing values from VF page to component controller..?

VF Page component class Not getting value of soID.query works if i pass hard coded ID.Please someone tell me where i am wrong..**The constructor gets called first, before any variables are set. I ...
1
vote
1answer
113 views

Removing an email template from a managed package

Is it possible to remove an email template from a managed package release? I used to want to distribute a template but I don't use it anymore so it just redundant.
4
votes
1answer
841 views

Upgrading email template

I have a package and make changes to an email template. Obviously, if I uninstall previous versions of the package and install a new version the template everything will be hunky dory. But, if I don'...
3
votes
1answer
68 views

Is it possible to define constants in an email template?

I am using an email template with a massive number of URLs. It has go to the stage where I'd like to define the URLs on the top of the page once and the use them in the template (some of them are used ...
4
votes
1answer
3k views

Spacing issue in Email Template

We have created a Custom(No Letterhead) email template with the name “B2AckReply” under “Unfiled Public Email Templates” and assigned it to Default Response Template in Web to Lead Settings. There is ...
5
votes
1answer
2k views

Sort Related list on visualforce email template

I have a visualforce email that show all case comments within a case. I'd like to sort the comments by created date (which is one of the columns). How can I achieve that? <messaging:...
6
votes
2answers
4k views

VisualForce page to allow inline editing of EmailTemplate HTML

Thanks for taking a look at my problem. I am building a VisualForce page to email all CampaignMembers associated with a Campaign record. Everything is working except for one little thing: I have an ...
4
votes
1answer
2k views

Pasting an image into the template of an outbound email

We are currently using the standard frame-based email templates which are supplied by SF. In one of our applications we occasionally need to manually create an email to send out to clients regarding a ...
6
votes
2answers
881 views

How to send an email before delete record using Email Template

I would like to send an email by using email template before delete a specific record. I'm using a before delete trigger and I receive the email, the problem is that the email is almost empty, without ...
11
votes
4answers
4k views

Test case failures due to VF email template

First, a little background information: I'm working on an end-to-end custom quoting solution that leverages the standard Quote object. We also utilize Sterling CPQ, which serves as the end-state for ...
3
votes
1answer
182 views

How to add ContentVersion data to an outbound email from a Trigger

So I have the following class: public static void sendmail(String documenttitle) { List<Id> contactids = new List<Id>(); List<user> con = new List<User>(); con = [...
1
vote
1answer
252 views

Dynamic reference to a property in an email template

In an email template it is possible to reference attributes by doing... "{!relatedTo.opportunity__r.CloseDate}" However, if the attribute must be in your model. If you did, "{!relatedTo....
0
votes
1answer
464 views

Office Word add-in error

A user recently started getting the following error when using Salesforce.com Office Edition Word add-in to try and open (and subsequently edit) a mail merge template: An internal server error has ...
1
vote
1answer
1k views

How to Customize the Email template on chatter posts

I want to customize the email template sent on the chatter post of the record with the @user full name to have some fields from the record. Is this possible, or how can I achieve this? Please help. ...
0
votes
1answer
135 views

Building up URL to include package name in email template

I can put a hyperlink to an Opportunity in an email template by doing: <a href="{!LEFT($Api.Partner_Server_URL_140, FIND('.com/',$Api.Partner_Server_URL_140)+3)}/{!opportunityId}> link </a&...
0
votes
1answer
479 views

Integrating an image into a email template using a component

Thanks to a good steer in this thread I have managed to get an image into an email template that I can package up and put in any org. My design: Stores the image as a document Uses a component with ...
1
vote
1answer
193 views

Set parameter in email?

Regarding a VisualForce email template, I know it is possible to setWhatId(), setSubject() and range of other things in Messaging.SingleEmailMessage. But I just want to set my own parameter. Let me ...
1
vote
2answers
93 views

Null in aggregate query

I have an image stored as a document. I put this image in an email template and reference it by doing: <img id="toplogo" src="{!LEFT($Api.Partner_Server_URL_140, FIND('.com/',$Api....
1
vote
1answer
286 views

Adding email to a package

I am trying to create an unmanaged package. When I try to add it, I get: "My Personal Email Templates" and "Unfiled Public Email Templates" cannot be added to a Package and are not shown in this ...
0
votes
1answer
2k views

Complex if statement in visual force email template

I need to check two things and based on outcome display some text. The two things are that the lastModified date of an opportunity is before one date and after another I try: <apex:outputPanel ...
0
votes
1answer
410 views

Displaying someting in email template based on a Date value

I am using a visual force template and want to add some logic which will decide whether to display something based on a date field in an Opportunity being less than a certain value. I try: <apex:...