TABLE OF CONTENTS
- Positioning images for best PDF output
- Working with Word tables
Avoid floating textboxes
Word and Excel both allow you to insert textboxes that "float" on top of the page or spreadsheet. While these can be really useful for getting positioning of content just right, we do not officially support textboxes in data templates. Some customers have reported satisfactory PDF results when using textboxes, but your mileage may vary.
When you need to position content in a precise manner on the page, we recommend using an Excel template. This is because Excel effectively provides "grid layout", which allows you to merge cells and resize rows/columns, which is ideal for a precision layout. If you must use Word, then try to use tables as much as possible to get similar results.
Always have page margins
Our PDF generation engine requires that your Word / Excel templates have at least a narrow page margin. Setting the page margins to zero will likely cause errors when converting to PDF.
Positioning images for best PDF output
Stay within page margins whenever possible
Generally speaking, it's always best to ensure that your images are not positioned in such a way that they overlap or "bleed" outside of the page margins. Use the Print Preview option in Word/Excel to verify this. When an image does bleed out, this often will cause the PDF output of your template to be inaccurate.
What if I need to place an image flush against the page edges in Word?
Placing images in the header or footer of your Word template can be problematic for PDF output. If you need your image to appear as a page width banner, we recommend that you use the following steps to achieve best PDF output:
- Paste/insert your image at the top of the page's text area.
- Right click on your image, choose Wrap Text -> More Layout Options
- In the dialog window, on the Text Wrapping tab, make sure the Wrapping Style is set to "Square."
- On the Position tab of the dialog, make sure:
- The Horizontal option is set to "Alignment" relative to "Page"
- The Vertical option is set to "Alignment" relative to "Page"
- Click OK to apply these settings. Your image should now be flush with the top and left of your page. If your image is wide enough, it will span the page.
This same approach can be used to position an image flush to the bottom or right of the page, too - the key is to use the Alignment options in the Position tab as outlined above.
Note that if you resize your image after doing the above steps, Word will likely change the image to use Absolute Position. This is not good for PDF output. So always check that your image is using the Alignment option for positioning of your image.
Don't use page-level columns with images in Word
You can set a page to use a columnar layout via Page Layout (in the Word ribbon) -> Columns. This is fine if your page is all text, however if you try to place images on a columned page - particularly images that bleed outside of the columns - you will likely have poor PDF output results.
If you want your text to appear in columns, always rather insert a Table with the desired columns, while keeping the Page Layout as a single column.
You'll still get the same desired columnar result, plus Tables are more flexible and compatible with PDF output.
Tables also enable you to create rows that can span multiple columns, so make use of this when you want to place an image that will span the page.
Working with Word tables
Set your column widths explicitly
For .pdf output's it is best to be explicit with your column widths. Don't assume that the word output (which often includes word applying auto adjustments to your column sizes) will match that of the .pdf's output.
Break rows with differing column sizes into separate tables
Never use tables where the column widths differ between rows (even though word will let you do this). If you have rows that have different column size requirements rather break those rows into separate tables.