Mail merge with Word (1 Viewer)

Tim Johnson

New member
Local time
Today, 19:15
Joined
Feb 15, 2000
Messages
8
I have a query that I am trying to merge with Word. I want the Word document to have a field CASENUMBER that may have more than 1 charge against it. The query works fine, in fact the merge with Word works fine. The problem is I want to be able to have the Word document list all charges (1 per line) against the CASENUMBER field. I don't want the user to have to cycle through each individual charge against the CASENUMBER.

ie.

CASENUMBER
CHARGE1
CHARGE2
CHARGE3
.
.
.

I don't see a way to loop through the records in Word (while not EOF) and print 1 record per line.

Is it even possible to display each individual charge against CASENUMBER?

any help would be greatly appreciated

Tim Johnson
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 14:15
Joined
Feb 19, 2002
Messages
43,213
If it is at all possible to produce this document using just Access, it will be much easier.

I had a similar problem. In my case the documents were mixing instructions for chemical formulas. The data being merged in was a list of chemicals and the quantities needed that were calculated based on the size of the batch being produced this time. The product being produced was hair color. Some of the product lines included 60 different shades. The mixing instructions for each shade in a product line were identical and except for the color component itself, all the chemicals and quanties were the same so it was important that they use a common word document.

After much research, I solved the problem by determining a maximum number of chemicals per formula and using two crosstab queries to produce the recordsource the word document needed.

The recordset had fixed field names so that the process could be standardized and the user could use a dummy recordset to build new word documents as needed.

The output of the two crosstabs was used as the recordsources for a third query that produced a recordset similar to:
Formula, BatchSize, MixingStation, more common fields, Chemical1, Quantity1, Chemical2, Quantity2, etc.

Since crosstabs can only produce one value at a time, if the data you need for each charge actually involves multiple fields, you will need to make as many crosstabs as you have fields related to a single charge. In my case, I had one to gather the chemicals and a second to gather the quantities.


[This message has been edited by Pat Hartman (edited 03-13-2000).]
 

Tim Johnson

New member
Local time
Today, 19:15
Joined
Feb 15, 2000
Messages
8
thanks Pat,

I'll give it a try

Tim Johnson
 

Users who are viewing this thread

Top Bottom