Activity Forums Salesforce® Discussions How can we insert a dynamic value in the Email Body of an Email Template in Salesforce?

  • Adarsh

    Member
    February 26, 2018 at 12:59 pm

    Hi Suryadeep,

    Yes, it is possible through 'VisualForce Email Template' type. you may pass dynamic values in this kind of email templates.

    Hope it helps 🙂

  • Parul

    Member
    September 18, 2018 at 1:31 pm

    Yes, you can use "VisualForce Email Template" by this you can pass dynamic values in Email template.

     

     

    Thanks

  • shariq

    Member
    September 20, 2018 at 11:46 pm

    Hi,

    You can pass the field value to the template like {!Accouont.Name}.

    Hope this helps.

  • Parul

    Member
    September 21, 2018 at 4:08 am

    Here is example;

    <messaging:emailTemplate subject="List of opportunity" recipientType="User" relatedToType="Account">
    <messaging:htmlEmailBody >
    Hi,<br/>
    Below is the list of opportunities for your account {!relatedTo.Name}.<br/><br/>
    <c:OpptyList AcctId="{!relatedTo.Id}" /><br/><br/>
    <b>Regards,</b><br/>
    {!recipient.FirstName}
    </messaging:htmlEmailBody>
    </messaging:emailTemplate>

     

    Thanks

Log In to reply.

Popular Salesforce Blogs