View Categories

Generating documents: examples

Here are a few examples of real-world document generation needs, along with an outline of the processes for fulfilling those needs.

Year-end tax letters by Household #

In this example, we’ll look at how to generate tax letters for your donors. The stated requirement here is that we wish to generate one document for each household, containing a list of all the donations given by any member of the household. We’ll assume that you are familiar with Apsona’s document generator. You might also find it helpful to read about generating sub-lists in documents. We’ll also assume that you are using (or familiar with) the Salesforce Non-profit Success Pack, which contains the Household and other related objects.

If you want to try this merge action in your org, you can download this file, and then import it into your org via Settings – Apsona items – Tools – Import in Apsona.

  1. The first step is to create a document template laid out in the format you want. Below is a screen shot of a simple template we will use. If you like, you can download the .docx file that produced this screen shot.

    For simplicity, we have included just seven “top-level” merge fields (FormalGreetingStreetAddressCityStateZipToday and TotalLastYear) pertaining to the household, to be produced from the main data source for the merge. It also contains three fields (NameDate and Amount) to be produced in the sublist. We have chosen Donations as the name of the sublist, as you can see from the TableStart tag in the screen shot above.

  2. Next, find the Account records for which you wish to generate letters. You can do this directly from the Account list, using a suitable filter, similar to the screen shot below.
  3. Click Tools – Merge/Mail to invoke the document generator, and select the document template alluded to above. In step 3 of the popup, match the fields of the template as below.

    Also:

    • Select the Opportunity object as data source for the Donations sublist, as in the above screen shot.
    • Set up a filter in the Filter tab so that only last year’s Opportunity records are included in the merge.
    • Set up a linkage so that the Record ID field of the Account object matches the field Opportunity.Account, to ensure that only the donations made by one of the contacts of the household will be included in the generated letter.
  4. When we generate the letter, it will look like this.

Powered by BetterDocs