RE: I want to send the PDF through email to the customer
I have created a Custom Record and then immediate a PDF form is created in
Customization > Forms > Advanced PDF / HTML Templates.
Now I want to send a PDF templated attached with email to the customer.
You have two options.
- Either customize the form and set your template PDF template.
Customiztion –> Forms –> Transaction Form. Select your form.
Change the Advanced Pdf template to your new generated one. - Using Scripting: You can use render module alongside the Email Module.
Create a script. Load Render Module. Call render.transaction(options) : Return file.File that contains a PDF or HTML document
then use email module to send email and attach your transaction.email.send({
author: userId,
recipients: userId,
subject: ‘Search completed’,
body: ‘CSV file attached, ‘ + noOfRows + ‘ record(s) found.’,
attachments: [tranasction object that you created from render]
});