+ Start a Discussion
b-liub-liu 

How do I create a Dynamic Email Signature?

Hey guys, I'm brand new to Apex and VisualForce.

 

I'm trying to find a way that I can build a dynamic email signature into my email template so that whoever is sending the email has his/her Name, Title, Phone, Mobile, and Email

 

I've tried this:

                   <p><font color="#CC0000">+</font> {!$User.name}<br />
                    <b>{!$User.owner.title}</b><br />
                    123 Holla Back St<br />
                     NEW YORK, NY 10014<br />
                    W: {!$User.phone}<br />
                    C: {!$User.mobile}<br />
                    {!$User.email}</p>

 

Been trying to look for another discussion board trying to make this work but unsuccessful.

ministe2003ministe2003

Depending what kind of email template you've set up, it might just be {!User.fieldname}  <- notice no $

Venkata Naresh Thatha 8Venkata Naresh Thatha 8
If you want fonts and other features, go for HTML Template. Please find the modified code suited for HTML template as below
You need to create a letter head initially for a HTML template where you can choose Font and other styles. Make sure the user has values for the fields like title,mobilephone,phone.
                    {!$User.Username}
                    {!$User.Title}
                    123 Holla Back St
                     NEW YORK, NY 10014
                    W: {!$User.Phone}
                    C: {!$User.MobilePhone}
                    {!$User.Email}