<messaging:emailTemplate subject="Case Report Type" recipientType="Contact" relatedToType="Account"

<messaging:htmlEmailBody >
    <style type="text/css">
      TH {font-size: 11px; font-face: arial;background: #CCCCCC;
           border-width: 1;  text-align: center }
      TD  {font-size: 11px; font-face: verdana }
      TABLE {border: solid #CCCCCC; border-width: 1}
      TR {border: solid #CCCCCC; border-width: 1}
    <font face="arial" size="2">
        <p>Dear {!recipient.name},</p>
        <p>Below is a list of Assets related to the Case: {!relatedTo.Name} </p>
        <table border="0" >
            <tr >

                <th>Case Number</th>
                <th>Owner Id</th>
            <apex:repeat var="cx" value="{!relatedTo.Cases}">

         Best Regards,

         <p />

In the Signature section of this template I want to get merge fields of logged in User instead of {!relatedTo.Name} . How do i achieve this?

1 Answer 1


You need the $User global variable:

Beest Regards,

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .