Mail Merge sub records

J

judith

I have a system where the user focuses on a record and then selects from
about 20 different letter templates options to print a letter. This all works
fine. I build a general query to pull off all possible data requierd and this
is mailmerged out to the selected template. The user is happy as they can add
and amend templates as required.

However they want to include data from a table that has multiple records and
include this as a list within the individual letters. My solution is to
create a mail base table. Append in the main record. Loop through the
multiple records and append them into fields on the flat record. I have set
up fields item1, price1, item2, price2, ..... There is a maximum number of
items selected. Then the mail merge is as before. Is there a better way to do
this please?
 
P

pietlinden

I have a system where the user focuses on a record and then selects from
about 20 different letter templates options to print a letter. This all works
fine. I build a general query to pull off all possible data requierd and this
is mailmerged out to the selected template. The user is happy as they can add
and amend templates as required.

However they want to include data from a table that has multiple records and
include this as a list within the individual letters. My solution is to
create a mail base table. Append in the main record. Loop through the
multiple records and append them into fields on the flat record. I have set
up fields item1, price1, item2, price2, ..... There is a maximum number of
items selected. Then the mail merge is as before. Is there a better way to do
this please?

:Like creating an ADO recordset, using GetString to convert the
recordset to a delimited chunk of text, and then using that to create
a table in Word? There's a nice example in Access Developer's
Handbook.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top