Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Removing blank lines from for letter
I am doing a mail merge using an excel data source, into word. Some of the
fields report a return of zero. I have managed to remove the 0 from the form letter replacing it with a space, but it will not suppress the line, and I am a bit stuck. Here is my code below {IF {MERGEFIELD "Employee"}0 "{Medical}"} Many thanks |
#2
|
|||
|
|||
Yes, the problem is that Word does not actually suppress any old blank line.
It only suppresses blank lines that are blank by being blank and having at least one blank MERGEFIELD field on them, and unfortunately an { IF } with a blank result doesn't count. If you happen to have a field in your sheet that you know is always blank, you could probably use { IF { MERGEFIELD Employee } 0 "{ Medical }" "" }{ MERGEFIELD myblankfield } But if you don't (and who would?) you can try putting the paragraph mark inside the result in the case where the field is non-blank, e.g. BeforeTheBlankLine { IF { MERGEFIELD Employee } 0 "{ Medical } " "" }AfterTheBlankLine should give you BeforeTheBlankLine Whatever is in medical AfterTheBlankLine or BeforeTheBlankLine AfterTheBlankLine Peter Jamieson "Phil" wrote in message ... I am doing a mail merge using an excel data source, into word. Some of the fields report a return of zero. I have managed to remove the 0 from the form letter replacing it with a space, but it will not suppress the line, and I am a bit stuck. Here is my code below {IF {MERGEFIELD "Employee"}0 "{Medical}"} Many thanks |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How do I skip line numbering on blank lines? | Page Layout | |||
footnote insert also puts 14 unwanted blank lines in middle of my. | Microsoft Word Help | |||
Where did "print blank lines" option go in Office 2003??? | Mailmerge | |||
Change Line Count to not count blank lines | Microsoft Word Help | |||
suppressing blank address lines in mail merge | Mailmerge |