Suppress Blank Table Rows in Mail Merge

B

Brett

Hi Everyone

I have a mail merge document that contains a table with 5
rows of information and a number of columns. When the
data is generated I may have from between 1 to 5 rows of
information depending upon the data stored for each
person. For those people that only have 1 row of non-
blank information I get 4 blank lines in the middle of the
letter. Is there anyway to dynamically resize the table
to ignore these blanks data lines. I cannot change the
source data as it will vary from 1 line of data to 5 lines
of data for each person and given the volumes I do not
which to do multiple runs.

Any ides

Brett
 
R

Roplab

Hi Brett,
I hope this will help you out there is a SuppressBlankLines
Property in Word VBA that you could use. Below is an example on how it
works.

Set myDoc = Documents.Open(Filename:="C:\Main.doc")
with myDoc
.SuppressBlankLines = True
.Destination = WdSendToPrinter(or any of the other parameter i.e
wdFormLetters)
.Execute
End With

I hope this answers your question

Good luck
-Ralph-
 

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