Re: complex mail merge in Word 2000 from Excel 2000 source
From: sheree (sah18_at_case.edu)
Date: 08/12/04
- Next message: Tricia: "Print Mail Merge Recipient List"
- Previous message: Chris Mitchell: "Problems with MailMerge - help needed."
- In reply to: Badger: "Re: complex mail merge in Word 2000 from Excel 2000 source"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 12 Aug 2004 08:18:27 -0400
Thanks so much for this example! It's the first example that even comes
close to what I am trying to do! I need to modify the example they've
given some, and very much appreciate your ideas. The code they have works
for only 2 groups. I need to modify this to work for 7 groups, but
preferably to work for an UNKNOWN number of groups. I'm very new to the
mail merge syntax and am not sure what my programming options are.
Ideally, I would like to detect any change in the grouping field (thus
indicating a new group), insert a page break, and then list out the fields
for the rows that correspond to the next group. So their code is close,
but I'm not quite sure how to adapt it to be more general.
Just to have it in this thread for others to view, here is the syntax from
the microsoft kb article (where <ENTER> represents a paragraph marker):
{ If { MERGESEQ } = "1" "{ MERGEFIELD City }" ""}<ENTER>
{ SET Place1 { MERGEFIELD City }}<ENTER>
{ If { Place2 } <> { Place1 }"<ENTER>
----------------------------Page Break--------------------------------
{ MERGEFIELD City }<ENTER>
<ENTER>
{ MERGEFIELD Employee }{ MERGEFIELD Sales }" "{ MERGEFIELD Employee
}{ MERGEFIELD Sales }" }{ SET Place2 { MERGEFIELD City }}<ENTER>
And here is the sample source file:
City Employee Sales
Atlanta Smith $3,000
Atlanta Gates $50,000
Atlanta Henderson $10,000
Houston Jones $8,000
Houston Kelley $9,000
Houston Peterson $0
And here is the sample output:
Atlanta
Smith $3,000
Gates $50,000
Henderson $10,000
----------------------------Page Break-----------------------------
Houston
Jones $8,000
Kelley $9,000
Peterson $0
Also, this merge example uses the Catalog document type. Is there a way
to add to this syntax column headers that appear only at the top of each
page (and aren't repeated for every row in the merge)? Or an overall page
header?
If possible, I'd like the merge data to appear in rows in a word table
(each piece of data in its own cell). Is there syntax for this also?
Thanks you so much for helping out!
-sheree
On Wed, 11 Aug 2004 19:48:05 +0100, Badger
<paul@nospam.badger19.fsnet.co.uk> wrote:
> Sheree,
>
> Try
> http://support.microsoft.com/?kbid=294686
>
> This is a good example of how to get this kind of merge to work and a lot
> easier than others to
> understand.
> If you're still baffled after reading this, let me know and I'll try to
> help.
> Done a few of these successfully in the past myself.
>
> Regards
> Paul
>
Using Opera's revolutionary e-mail client: http://www.opera.com/m2/
- Next message: Tricia: "Print Mail Merge Recipient List"
- Previous message: Chris Mitchell: "Problems with MailMerge - help needed."
- In reply to: Badger: "Re: complex mail merge in Word 2000 from Excel 2000 source"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|