Introduction

You may need to use a different form backdrop for different pages of a multi-page document. For example, we may have a header form containing the company logo, a continuation page and a footer form with contact and legal details.

Applies To

Spindle Professional 2009 - 2012

Spindle Professional v6

Spindle Document Distribution v7 and later

Solution

You can specify a backdrop form using either of two methods:

a) using the Default Form tab of a document operation in Spindle Document Distribution Tools

b) by adding a ##FORM...## command to the document layout.


We will create four backdrop forms using the design package of choice, in my case I will use MS Word. These four forms will cover all eventualities:

The current page is the only page in the document

The current page is the first of several pages in the document

The current page is the last of several pages in the document

The current page is neither the first nor the last of several pages in the document



We can add the command to the layout using the report writer's own logic tests, comparing the current page number with total number of pages. This information is commonly found in report writers to allow a page numbering style of Page 1 of 3 for example.


If the total number of pages is 1, then it is a single-page document

If not, then if the current page number is 1, it is the first page of a multi-page document, 

If neither of the above are true, and the current page number is equal to the number of pages, it is the last page of a multi-page document

If none of the above apply, the page is a continuation page, with at least one page before it and at least one after it.


The syntax of the command will vary depending on the ERP and its report writer. I have added some examples below:


Sage 200

REPORT.PAGES = 1? "##FORM SinglePage##": REPORT.PAGE = 1? "## FORM First Page##": REPORT.PAGE = REPORT.PAGES? "##FORM LastPage" : "##FORM MiddlePage##"





KBA details

Related ProductSpindle Professional
Reference NumberKBA-01-02-039
Document Date12/01/2021
Original AuthorVince Hodgson
Document Version1.0
Last Updated12/01/2021
Update AuthorVince Hodgson
KeywordsSpindle Professional, ATTACH, ATTACHDIR, Invoices, Statements, Attachments