Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Supressing varying number of rows for each recipient
I am using Access as my data source.
The project is a debt collection letter merge. Each recipent has a different number of items due. The relevant part of the record layout is as follows: [Desc_1]; [Amt_1] [Desc_2]; [Amt_2]....[Desc_n]; [Amt_n] The Description field is always NOT NULL; however, the Amount field may be null. If the Amount field is null, how do I supress it and the corrresponding Description? Thanks, -- Albert Chen |
#2
|
|||
|
|||
Use an If...then...Else field construction to check the amount fields.
-- 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 "Albert" wrote in message ... I am using Access as my data source. The project is a debt collection letter merge. Each recipent has a different number of items due. The relevant part of the record layout is as follows: [Desc_1]; [Amt_1] [Desc_2]; [Amt_2]....[Desc_n]; [Amt_n] The Description field is always NOT NULL; however, the Amount field may be null. If the Amount field is null, how do I supress it and the corrresponding Description? Thanks, -- Albert Chen |
#3
|
|||
|
|||
Hi Doug: Thanks for the reply; however, how does If Then Else apply to merge
fields? I have only seen it used to insert messages as Word Fields. Please post a brief example of your solution. Thanks very much. -- Albert Chen "Doug Robbins" wrote: Use an If...then...Else field construction to check the amount fields. -- 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 "Albert" wrote in message ... I am using Access as my data source. The project is a debt collection letter merge. Each recipent has a different number of items due. The relevant part of the record layout is as follows: [Desc_1]; [Amt_1] [Desc_2]; [Amt_2]....[Desc_n]; [Amt_n] The Description field is always NOT NULL; however, the Amount field may be null. If the Amount field is null, how do I supress it and the corrresponding Description? Thanks, -- Albert Chen |
#4
|
|||
|
|||
{IF {Mergefield Amt_1] "" "{Mergefield Desc_1} {Mergefield Amt_1}
"}etc -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Albert wrote: Hi Doug: Thanks for the reply; however, how does If Then Else apply to merge fields? I have only seen it used to insert messages as Word Fields. Please post a brief example of your solution. Thanks very much. Use an If...then...Else field construction to check the amount fields. -- 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 "Albert" wrote in message ... I am using Access as my data source. The project is a debt collection letter merge. Each recipient has a different number of items due. The relevant part of the record layout is as follows: [Desc_1]; [Amt_1] [Desc_2]; [Amt_2]....[Desc_n]; [Amt_n] The Description field is always NOT NULL; however, the Amount field may be null. If the Amount field is null, how do I supress it and the corrresponding Description? Thanks, -- Albert Chen |
#5
|
|||
|
|||
Thank you.
-- Albert Chen "Graham Mayor" wrote: {IF {Mergefield Amt_1] "" "{Mergefield Desc_1} {Mergefield Amt_1} "}etc -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Albert wrote: Hi Doug: Thanks for the reply; however, how does If Then Else apply to merge fields? I have only seen it used to insert messages as Word Fields. Please post a brief example of your solution. Thanks very much. Use an If...then...Else field construction to check the amount fields. -- 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 "Albert" wrote in message ... I am using Access as my data source. The project is a debt collection letter merge. Each recipient has a different number of items due. The relevant part of the record layout is as follows: [Desc_1]; [Amt_1] [Desc_2]; [Amt_2]....[Desc_n]; [Amt_n] The Description field is always NOT NULL; however, the Amount field may be null. If the Amount field is null, how do I supress it and the corrresponding Description? Thanks, -- Albert Chen |
#6
|
|||
|
|||
I must be missing something.
The following is displayed in the body of my letter: {IF 10.00 "" Late Payment Penalty 10.00 } {IF "" Interest Charge } So the test is not being performed because it is just merging the Amount field twice. Please help me resolve this. Thanks again. -- Albert Chen "Graham Mayor" wrote: {IF {Mergefield Amt_1] "" "{Mergefield Desc_1} {Mergefield Amt_1} "}etc -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Albert wrote: Hi Doug: Thanks for the reply; however, how does If Then Else apply to merge fields? I have only seen it used to insert messages as Word Fields. Please post a brief example of your solution. Thanks very much. Use an If...then...Else field construction to check the amount fields. -- 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 "Albert" wrote in message ... I am using Access as my data source. The project is a debt collection letter merge. Each recipient has a different number of items due. The relevant part of the record layout is as follows: [Desc_1]; [Amt_1] [Desc_2]; [Amt_2]....[Desc_n]; [Amt_n] The Description field is always NOT NULL; however, the Amount field may be null. If the Amount field is null, how do I supress it and the corrresponding Description? Thanks, -- Albert Chen |
#7
|
|||
|
|||
Did you insert the field boundaries with CTRL+F9?
-- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Albert wrote: I must be missing something. The following is displayed in the body of my letter: {IF 10.00 "" Late Payment Penalty 10.00 } {IF "" Interest Charge } So the test is not being performed because it is just merging the Amount field twice. Please help me resolve this. Thanks again. {IF {Mergefield Amt_1] "" "{Mergefield Desc_1} {Mergefield Amt_1} "}etc -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Albert wrote: Hi Doug: Thanks for the reply; however, how does If Then Else apply to merge fields? I have only seen it used to insert messages as Word Fields. Please post a brief example of your solution. Thanks very much. Use an If...then...Else field construction to check the amount fields. -- 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 "Albert" wrote in message ... I am using Access as my data source. The project is a debt collection letter merge. Each recipient has a different number of items due. The relevant part of the record layout is as follows: [Desc_1]; [Amt_1] [Desc_2]; [Amt_2]....[Desc_n]; [Amt_n] The Description field is always NOT NULL; however, the Amount field may be null. If the Amount field is null, how do I supress it and the corrresponding Description? Thanks, -- Albert Chen |
#8
|
|||
|
|||
No. I will try it that way. Thanks.
-- Albert Chen "Graham Mayor" wrote: Did you insert the field boundaries with CTRL+F9? -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Albert wrote: I must be missing something. The following is displayed in the body of my letter: {IF 10.00 "" Late Payment Penalty 10.00 } {IF "" Interest Charge } So the test is not being performed because it is just merging the Amount field twice. Please help me resolve this. Thanks again. {IF {Mergefield Amt_1] "" "{Mergefield Desc_1} {Mergefield Amt_1} "}etc -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Albert wrote: Hi Doug: Thanks for the reply; however, how does If Then Else apply to merge fields? I have only seen it used to insert messages as Word Fields. Please post a brief example of your solution. Thanks very much. Use an If...then...Else field construction to check the amount fields. -- 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 "Albert" wrote in message ... I am using Access as my data source. The project is a debt collection letter merge. Each recipient has a different number of items due. The relevant part of the record layout is as follows: [Desc_1]; [Amt_1] [Desc_2]; [Amt_2]....[Desc_n]; [Amt_n] The Description field is always NOT NULL; however, the Amount field may be null. If the Amount field is null, how do I supress it and the corrresponding Description? Thanks, -- Albert Chen |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How do I insert chapter number with page number in footer? | Microsoft Word Help | |||
Page numbering in footers, Outside margin, Page Number + Number of Pages | Page Layout | |||
Maximum number of pages in a word document | Formatting Long Documents |