Through the Lookups we are able to store and use HTML templates to generate a PDF using form fields.
Navigate to the Shared Lookups Modules (top left) → Module Name → Shared Lookups (tab)
Select the ‘+Add’ button in the top right.
Name the new Shared Lookup 'HTML Templates'.
From the right mounted palette add a Long Text field.
Select the Wrench icon to open the field properties enable the 'Is HTML' checkbox
Save the Lookup form and close the Lookup form editor.
Add the HTML formatted template into the field configured to support HTML templates.
Navigate to the Field List.Modules (top left) → Module Name → Forms (tab) → Field List
Select 'Add Field' in the top right.
Enter an descriptive Internal Name, System Name, and select ‘Attachment' for the type.Such as: 'PDFAttachment’
Save the Field List.
Navigate to the Shared Lookups Modules (top left) → Module Name → Workflow (tab) → Workflow Name
Select the Action which will generate the PDF Attachment.
Select the Subactions tab.
Add a ‘New Section’, followed by selecting the menu icon to the right.
Within this menu select 'Generate attachment'.
Set the Template to be used on the left, and the Attachment field to store it on the right.
When the Action is performed the PDF will be generated and stored in the Attachment field.
Accessing the attachment from the form:Adding the Attachment field to the Default Form will allow the Attachment to accessible on the form and viewed when generated.
To include the attachment in an Email:In the email template add %(extendedfieldPDFAttachment)%Replace the value accordingly if your attachment field internal name varies %(InternalFieldNameHere)%