Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.newusers
Blesson Blesson is offline
external usenet poster
 
Posts: 1
Default Word mail merge/Table formatting

I am currently using a mail merge document to perform a function. The
document generates letters which contains a table with 4 columns and number
of rows. I am trying to set the mail merge document such that when I perform
the merge function every table within every letter that is generated is
sorted in ascending order. In short, I am trying to avoid going to each
letter and sort the tables manually.
Any help is appreciated.
--
BK
Phila, PA
  #2   Report Post  
Posted to microsoft.public.word.newusers
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default Word mail merge/Table formatting

Not sure how you are populating the table, but if you execute the merge to a
new document, you could run a macro containing the following code to sort
each of the tables.

Dim atable As Table
For Each atable In ActiveDocument.Tables
atable.Sort
Next atable

You may need to add a few more parameters to the .Sort command to achieve
exactly what you are after. Check out Sort in the Visual Basic Editor to
see the options that are available.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Blesson" wrote in message
...
I am currently using a mail merge document to perform a function. The
document generates letters which contains a table with 4 columns and
number
of rows. I am trying to set the mail merge document such that when I
perform
the merge function every table within every letter that is generated is
sorted in ascending order. In short, I am trying to avoid going to each
letter and sort the tables manually.
Any help is appreciated.
--
BK
Phila, PA



Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Mail merge does not keep formatting from excel into word document Luke Mailmerge 2 August 8th 07 12:33 AM
word table merge field formatting Rick Stahl Mailmerge 3 February 3rd 06 07:16 AM
formatting numbers mail merged into Word table from an Excel Works Jeannie McQuaid Tables 1 July 27th 05 10:06 PM
How do I control date formatting in a Word Mail Merge? Ric McWaters Mailmerge 1 April 21st 05 04:23 PM
Formatting zip code in mail merge from Excel to Word Zip code help Microsoft Word Help 1 February 10th 05 01:50 AM


All times are GMT +1. The time now is 05:31 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"