Inforama tutorial
You can download the Inforama project files for this example by clicking the attachments link at the bottom of this page.
Once letter templates have been setup it's possible to email them. In doing so the email body which will be addressed to the user needs to be defined. Once again OpenOffice is used to create these templates.
Configuring the SMTP Settings
Before you send emails you will need to configure your Inforama project with valid SMTP settings. Click the Project – Properties... menu item to display the Project settings dialog as shown in figure 2.

Figure 1: The project settings dialog
Select the email node from the tree on the left of the dialog and enter some valid SMTP settings similar to those shown in figure 2.
Create an Email Template
Now to create the email template click the File – New document... menu item to show the New document dialog shown in figure 2.

Figure 2: Create a new email template with the new document dialog
Enter the name of the email template you wish to create – in this case the name is WelcomeMail. Select Email as the document type from the dropdown list. The new template will appear in the tree in the document frame in the editor and will also open in the OpenOffice editor.
Create the email template with whatever datafields and parameters you want within the email body. An example email template is shown in figure 3 below.

Figure 3: The email template
This template contains an image. This image needs to be inserted into the document as a linked image and not embedded within the document. To make sure that it's done in this way click the button indicated by the toolbar button 1 in figure 3.
Now it's possible to test how this email template will appear when it's emailed to a customer. Click the button indicated by the toolbar button 2 in figure 3 and the dialog shown in figure 4 will appear.

Figure 4: The email parameter dialog
Enter the email address to which you want to send the email and also enter a sample email subject. Any parameters which are required by the email can be entered in this dialog. When the information has been entered click the Send an email button to send it and it will arrive in your email client as shown in figure 5.

Figure 5: The test email viewed in the email client
Creating a compound document
You can create a compound document which will consist of several different elements using the Letter manager dialog. Click the Project – Manage documents... menu item to display the Letter manager dialog shown in figure 6.

Figure 6: The letter manager dialog
Add the CustomerRentalsClass letter template to the list of selected fragments and select the WelcomeMail Email template from the dropdown list. Enter a name for the compound document you want to create and also enter the email subject which is going to appear when the email arrives. Click the Save document button to save the compound document.
You can test the email process within the Studio using the Documents and Packs Generator dialog. Click the Project – Generate documents and packs... menu item. The dialog shown in the first page of figure 7 will be displayed.

Figure 7: Steps 1 & 2 of the document generator
Leave the request type as the default Normal and select the CustomerRentalsEmail document from the list of avaliable documents. Click the Next button and on the second page select the CustomerRentalsEmail. Select the Email parameters checkbox and enter the email address to which the email should be sent. Click the Next button and the first screen shown in figure 8 will be displayed.

Figure 8: Steps 3 & 4 of the document generator
Enter the parameters required for the generation process and click the Next button. The email will be sent and finally the second screen shown in figure 8 will be displayed.

Figure 9: The emailed letter
This time when the email arrives the generated letter will be attached and can be opened by the recipient.
Creating Packs
If you want to send multiple documents in a single email you can organise several documents into a pack. Click the Project – Manage packs... menu item to display the dialog shown in figure 10.

Figure 10: Creating a pack with the pack manager
Move the documents you want to include as part of this pack to the selected documents list on the right of the dialog. Enter a name for the pack, select the WelcomeMail email template and enter an email subject. Click the Save pack button to save it and close the dialog.
Click the Project – Generate documents and packs... menu item once again to display dialog shown in the first page of figure 7. This time the new pack will be displayed in the dialog and when you send it by email it will have the two pack documents attached.