Skip to main content
The 2024 Developer Survey results are live! See the results
6 votes
Accepted

Multi-lingual Visualforce email templates

After doing some research I able to figured out how to achieve this, if someone has better way of doing please post it here. 1) I modified my VF email template and added attribute language="{!...
Nick's user avatar
  • 7,074
4 votes

Dynamic Subject in a Visualforce email template

Okay ,I just figured it out , Posting the updated code here so that it could help someone else :-) <messaging:emailTemplate subject="Case Description :{!relatedto.Description } Created Date : {!...
Natasha's user avatar
  • 127
4 votes
Accepted

workflow rule and email alerts firing in user context

Workflow Rules evaluate in System context. Field Updates also update in System context. Email Templates, however, honor the field security of the user, because otherwise users could render templates ...
sfdcfox's user avatar
  • 497k
4 votes

Salesforce Visualforce Email Template {!Recipient.Name} does not have the correct value

For anyone coming to this page with a similar question but due to Changed Password / Reset Password inside an Experience Site not properly merging in the recipient fields, here's what I did: Create a ...
Rebekah Oakes's user avatar
3 votes

What are we achieving with Visualforce templates in Salesforce

Visualforce templates are used in: 1. Communities: for example in the communities all the pages have same header and footer (say branding), then we can use vf template which will have only the header ...
Krishna Bidwai's user avatar
3 votes
Accepted

vf email template can be editable once it managed?

Yes you can ! refer following link for more details Editing Components and Attributes After Installation |Subscriber and Developer Editable |Locked
Nachiket Deshpande's user avatar
3 votes
Accepted

Conditional rendering using IF in Visualforce Template

As mentioned by Tushar, relatedTo is a single record, not a list. Merge fields always start with {! and end with }. You forgot the !. Also, you don't need an "IF" statement here: rendered="{!...
sfdcfox's user avatar
  • 497k
3 votes
Accepted

Error: Invalid child of messaging:emailTemplate. Only messaging components are allowed as children of messaging:emailTemplate

As the error says, you can't put other markup outside of the messaging elements. Here's the fix: <messaging:emailTemplate subject="Your Offering Listing" recipientType="Contact" ...
sfdcfox's user avatar
  • 497k
2 votes
Accepted

Add > in Visualforce Template Email Subject

Here is the one workaround for the same, use this : {!RIGHT('>',2)} Here is the out put :
Tarun Jain's user avatar
2 votes
Accepted

Merging Case fields into Visualforce email template?

Your friend here is the setWhatId(someCaseId) method as documented here in the Apex doc This corresponds to the {!relatedTo.Id} merge field in the VF email template that you can pass into your custom ...
cropredy's user avatar
  • 72.2k
2 votes

Can't we use more than one custom object in vf template?

Can I pull fields across objects on an email template? Resolution The Email Template function cannot process multiple objects. From a custom object you can pull in all the fields that have a Parent ...
Devendra's user avatar
  • 5,075
2 votes
Accepted

Displaying user's profile picture dynamically in email template

Access to User.SmallPhotoURL or User.LargePhotoURL needs authentication. In your case this might be a issue. Instead use ChatterUsers class to get the photo URls. There is a variable called ...
Saroj Bera's user avatar
  • 14.8k
2 votes
Accepted

Add User Profile Picture to VisualForce Email Template

The PhotoUrl is not available with $User global variable. You need to query it in order to use with your template. So, you would need a controller along with the Visualforce template. Since, the ...
ipradhansk's user avatar
  • 2,337
2 votes
Accepted

Visualforce component applyBodyTag work-around

Generally, when I'm doing that I leave the styling in the Visualforce page and the Email Template and just have the content in the Component <apex:page renderAs="pdf" showHeader="false" sidebar="...
Phil Hawthorn's user avatar
2 votes

Is possible to use a Visualforce email template whose content can be freely edit?

This can be done using this Appexchange package (from Salesforce Labs). You can make a flow that pre-populates this component with a VF email template, make edits, then send the email. You will need ...
Caleb Murphy's user avatar
1 vote

Are Visualforce templates possible in Visualforce email templates?

You can use custom Visualforce Components and then use it inside your Visualforce Email Template. I used similar thing in one of the projects, and it works. Salesforce References: VF Email Template ...
Milan Nakum's user avatar
1 vote

Using Custom Controllers within Visualforce Email Templates

In your component you need to use the variable you are not using it. Also I suggest you as better practice use Proper name for controller and follow proper naming conventions. <apex:component ...
Tushar Sharma's user avatar
1 vote
Accepted

Visual-force Email Template working for Test but in Actual Alert it is not displaying all values

Per your comment: ... some fields are read[] only and visible to only System Admin Visualforce enforces Field-Level Security. If you wish this data to be rendered into the template, you must expose ...
David Reed's user avatar
  • 93.2k
1 vote

VF outputtext with value if contains condition and currency format

You can decompose the problem into pieces The rendering condition (in a wrapper outputPanel) The markup including formatted currency <apex:outputPanel rendered="{!CONTAINS(relatedTo....
cropredy's user avatar
  • 72.2k
1 vote

Custom Lightning Record Page Template not showing up in Template Switching Wizard

It may just take time for it to show up in the template list. I tested with a new custom template a few days ago, and it showed up immediately for new Lightning record pages, but it did not show as an ...
Zosoled's user avatar
  • 103
1 vote
Accepted

Visualforce Email Template - broken images for all Email Clients? Workaround?

Neither of your URLs are correct. Your code should include the server (emails are naturally not on the same server as Salesforce), and you need to verify the parameters you're putting in to the URL. ...
sfdcfox's user avatar
  • 497k
1 vote

Images in PDF attachment of a Visualforce email Template

The problem you're having is that PDF rendering doesn’t support images encoded in the 'data: URI' scheme format. See Adding Attachments. You've not set the image link in CORS, so the render engine ...
crmprogdev's user avatar
1 vote

vf email template can be editable once it managed?

Yes you can modify the VF email template once they are part of manage package. You can edit the body. I have done it myself as well.
Tushar Sharma's user avatar
1 vote
Accepted

Use logged in user merge fields in visualforce email template

You need the $User global variable: Beest Regards, {!$User.Name}
Adrian Larson's user avatar
  • 151k
1 vote
Accepted

VF Email Template

One option can be possible. Create a custom subject text field in the Object. Use this custom subject text in your email templates. Update this custom subject text field in the Custom button send ...
Santanu Boral's user avatar
1 vote

Japanese character displays in Visualforce template but in PDF it shows question marks (???)

There are two things would apply here. From Fonts Available When Using Visualforce PDF Rendering: Arial Unicode MS, Helvetica, Times and Courier. These rules apply to server-side PDF rendering. ...
crmprogdev's user avatar
1 vote

How to create page block in visual force email template

Nobody is going to write a HTML file for you. :) When you render a Visualforce page in your browser, the browser doesn't know whether its a visualforce page or any other type. From the browser's POV, ...
Santanu Halder's user avatar
1 vote

How to have a field display without a decimal

By Using <apex:outputText> you will able solve your problem.... Let say you want show In_Network_Major__c field without decimal value then to need use outputtext with below format: <apex:...
Avijit Das's user avatar
  • 1,416
1 vote

How to have a field display without a decimal

You can use FLOOR to omit decimals <apex:outputText value="{!FLOOR(sObj.decimal_field__c)}"/> If the decimal_field__c value is 12.00 or 12.01 or 12.99, It will show 12
Santanu Boral's user avatar
1 vote

IF THEN Statement in VisualForce Email Template

This should run your formula and render the results to the VF page. Try this. rendered="{!IF(ISNULL(TimeclockStartDate__c), NULL, '<li type=\"circle\"> Time Clock ...
Apex N-u-b's user avatar
  • 1,308

Only top scored, non community-wiki answers of a minimum length are eligible