Download PDF
Download page Working with Rich Text Area Fields.
Working with Rich Text Area Fields
FX2 formatted templates can take advantage of Rich Text Area (RTA) fields by rendering them as HTML. You can use RTA fields in your template documents to include pre-formatted text, tables and images when documents are generated. You take care of this in X-Author Contracts when you insert Rich Text fields and choose how they should be rendered.
In pre-existing format, RTA fields are only supported by rendering them as an image. For FX2 documents, it is recommended to use "Render as HTML" when your content does not contain images. It is still recommended to "Render As Image" RTA fields when you are inserting a field containing images and no other content. For instructions on inserting image references into templates for rendering as image, refer to Image References in Templates (FX2).
Configuring Rich Text Area Fields
Before you can use Rich Text Area fields in agreement templates, you must first create the fields on the Agreement object. For proposal templates, use the same process for the Quote/Proposal object.
To create an RTA field
- Go to Setup > Create > Objects > Agreement.
- Under Custom Fields & Relationships, click New.
- Select Text Area (Rich) and click Next.
- Enter a Field Label and Field Name, such as RTF Content 1, and click Next.
- Set field-level access and click Next.
- Click Save. The Rich Text Area is now available from the Fields list when you edit a page layout. Create additional RTA fields to hold other pre-formatted content.
To add RTA fields to the Agreement layout
- Go to Setup > Create > Objects > Agreement > Page Layouts and select the layout that will contain your RTA fields.
- From the Fields list, select the RTA fields you want to use and add them to the Information section or add them to a new or existing section.
- Click Save. Repeat steps 1 – 3 for any other required Agreement object page layouts. You can use this same process for the Quote/Proposal object.
How to Prepare Rich Text Content for Templates
X-Author templates only support Rich Text content developed using the Rich Text editor in Salesforce. RTA fields inside templates generate field content exactly as shown on the agreement record. Before generating an agreement based on a template containing RTA fields, edit the agreement record directly to format your Rich Text content.
Be aware that copy-paste or data loading of Rich Text content that includes formatting not available using the editor (e.g., tables) may or may not appear correctly in generated documents. Refer to Salesforce documentation for HTML limitations if attempting to include RTF content in this way.
To insert RTA fields into a template
- Open Microsoft Word and connect to X-Author Contracts.
- From the X-Author Templates tab, create a new template or check-out an existing template.
- Click Insert Fields. The Insert Field dialog is displayed.
- Select the Agreement object and the Rich Text field you want to insert. Hold Ctrl and select any additional fields to insert them in the order selected.
- Click Finish to insert the field into your template. The Rich Text field is inserted and displayed in the Control Panel with the appropriate icon.
- Highlight the Rich Text field in the Control Panel. The Properties pane below the Control Panel displays attributes for the field.
- Next to "Render As" click the drop-down and choose HTML, if it is not already selected.
Continue to insert fields or check-in your document.
You cannot insert RTA fields into the header/footer of a template.
Tip: Controlling HTML Content Width
If your RTF field contains large HTML content, and you want to control the width of the output in the generated document, follow these steps:
- Prior to inserting your RTF field that contains large content, insert a table with only one cell.
- Right-click the table and select Auto Fit/Fixed Column Width and adjust the table to your desired width.
- Insert the RTF field into the one-cell table. The generated document content will use the selected width and grow downward.