Microsoft KB Archive/57654

Word: Suppressing Blank Lines in Print Merge Documents

PSS ID Number: Q57654 Article last modified on 11-02-1994

4.00 5.00

MS-DOS

= SUMMARY =

In Microsoft Word versions 4.0 and 5.0 during a print merge, blank lines sometimes occur in the final merged document. This happens if some of the data records in the data document have field entries that do not contain information (the field entry position is held by a comma) and if improper IF and ENDIF syntax is used.

= MORE INFORMATION =

For example, in letter addresses, data records may or may not contain field entries containing job titles, company names, or second lines of street addresses. To avoid having blank lines result in the final merged document where a field entry is skipped, use the following syntax for the data and main documents:

Data Document
name,title,company,address1,address2,city,state,zip Hugh Lizt,Vice President,Willie Washer Co.,1929 Rain Lane,Building K,Brooklyn,NY,29834 Rosa Steel,Head of Advertising,“BigWig Images, Ltd.”,Chant Plaza,,Los Angeles,CA,01983 Lynne Fester,,,Box 19723,,Zoe,OR,09721

The longer data records have been allowed to wrap around to a second line. When the content of a field entry is skipped, a comma is inserted to hold the place.

Main Document
<>

< > <>< <>< > <>< > <>< > <, < > < > Dear < >:

etc.

Take care not to insert spaces between the field names in chevrons. If this is done, the spaces will appear at the beginning of each merged line in the resulting document, causing the left margin to look misaligned. Each ENDIF statement is terminated with a paragraph mark by pressing ENTER.

If the syntax in the example is followed exactly, there won’t be any blank lines or blank spaces in the final merged document.

KBCategory: kbother KBSubcategory: kbmerge Additional reference words: ============================================================================= Copyright Microsoft Corporation 1994.