Ajax (1) Apex Class (12) Apex Trigger (2) Community (2) Home Page (1) HTML (4) Integration (3) JS (7) KB (1) Label (1) Licenses (1) Listing (1) Log (1) OOPs (5) Sharing (1) Static Resource (1) Test Class (3) URI (1) Visualforce (10)

Tuesday 22 April 2014

massaging Attachment


    <messaging:emailTemplate recipientType="Contact"                          
relatedToType="Account"
subject="Case report for Account: {!relatedTo.name}"
replyTo="support@acme.com"> <messaging:htmlEmailBody> <html> <body> <p>Dear {!recipient.name},</p> <p>Attached is a list of cases related to {!relatedTo.name}.</p> <center> <apex:outputLink value="http://www.salesforce.com"> For more detailed information login to Salesforce.com </apex:outputLink> </center> </body> </html> </messaging:htmlEmailBody> <messaging:attachment renderAs="PDF" filename="yourCases.pdf"> <html> <body> <p>You can display your {!relatedTo.name} cases as a PDF</p> <table border="0" > <tr> <th>Case Number</th><th>Origin</th> <th>Creator Email</th><th>Status</th> </tr> <apex:repeat var="cx" value="{!relatedTo.Cases}"> <tr> <td><a href = "https://na1.salesforce.com/{!cx.id}">{!cx.CaseNumber}
</a></td> <td>{!cx.Origin}</td> <td>{!cx.Contact.email}</td> <td>{!cx.Status}</td> </tr> </apex:repeat> </table> </body> </html> </messaging:attachment> </messaging:emailTemplate>

             Thanks & Regards,
             Krishnanand Gupta
   +91-9410670463,+91-9015574663
        http://www.kg91.weebly.com





No comments:

Post a Comment