If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Mail Merging Certain Rows from Text Source
Good morning,
I have a letter in Word XP that I am using mail merge in order to import from a ; delimitted text file. It imports the data fine but I have a question. The letter should only go out to people who have GR as the value in the GR field. I used the IF statement to conditionalize fields, however if the person does not have GR as the value it simply makes a letter with all the merge fields blank. Is there a way to make it only do letters for those with GR as the value? And example of my current formula is: {IF {MERGEFIELD GR} = "GR" "{MERGEFIELD "First_Name"}" ""} I thought about removing the last set of quotation marks but I don't know if that will break the logic. Any advice would be great. Thanks Jonathan |
#2
|
|||
|
|||
Assuming you are only producing one letter for each record in the data
source, or that it is always safe to ignore all records where the value in GR is GR, try this: a. make a backup copy of your document, just in case b. remove the IF field c. Use Tools|Customize to enable the Mail merge toolbar. Click the Mail Merge Recipients button (typically the third from the left) d. click the little arrow in the column heading of the "GR" column, and, if Word lets you select the value "GR", do that, and the list of records should be filtered. If you don't see a GR value, click the Advanced... option, and specify the condition where the GR field equals GR. You should not need to put any quotes around the GR. e. Come out of the dialog box and save and close your document. Then try opening it again to verify that Word has remembered its data source, and the filter condition. If it has, you're probably OK and you should get what you need. if not (and that may be the case in Word XP unfortunately), further thought is needed... Peter Jamieson "jdawgnat" wrote in message oups.com... Good morning, I have a letter in Word XP that I am using mail merge in order to import from a ; delimitted text file. It imports the data fine but I have a question. The letter should only go out to people who have GR as the value in the GR field. I used the IF statement to conditionalize fields, however if the person does not have GR as the value it simply makes a letter with all the merge fields blank. Is there a way to make it only do letters for those with GR as the value? And example of my current formula is: {IF {MERGEFIELD GR} = "GR" "{MERGEFIELD "First_Name"}" ""} I thought about removing the last set of quotation marks but I don't know if that will break the logic. Any advice would be great. Thanks Jonathan |
#3
|
|||
|
|||
Thank you - it worked like a charm.
Peter Jamieson wrote: Assuming you are only producing one letter for each record in the data source, or that it is always safe to ignore all records where the value in GR is GR, try this: a. make a backup copy of your document, just in case b. remove the IF field c. Use Tools|Customize to enable the Mail merge toolbar. Click the Mail Merge Recipients button (typically the third from the left) d. click the little arrow in the column heading of the "GR" column, and, if Word lets you select the value "GR", do that, and the list of records should be filtered. If you don't see a GR value, click the Advanced... option, and specify the condition where the GR field equals GR. You should not need to put any quotes around the GR. e. Come out of the dialog box and save and close your document. Then try opening it again to verify that Word has remembered its data source, and the filter condition. If it has, you're probably OK and you should get what you need. if not (and that may be the case in Word XP unfortunately), further thought is needed... Peter Jamieson "jdawgnat" wrote in message oups.com... Good morning, I have a letter in Word XP that I am using mail merge in order to import from a ; delimitted text file. It imports the data fine but I have a question. The letter should only go out to people who have GR as the value in the GR field. I used the IF statement to conditionalize fields, however if the person does not have GR as the value it simply makes a letter with all the merge fields blank. Is there a way to make it only do letters for those with GR as the value? And example of my current formula is: {IF {MERGEFIELD GR} = "GR" "{MERGEFIELD "First_Name"}" ""} I thought about removing the last set of quotation marks but I don't know if that will break the logic. Any advice would be great. Thanks Jonathan |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
oe6 reading mail showing as html raw source? | Bill Kearney | Outlook Express | 40 | October 9th, 2005 05:39 AM |
mail merge main document. Word cannot find its data source | Marvin Herrera | Mailmerge | 1 | November 23rd, 2004 12:00 AM |
Concatenatd fields in a query for a searching form | Marc | Running & Setting Up Queries | 8 | October 19th, 2004 08:49 PM |
Help with mail merging using a Text File | Steven Moschidis | Mailmerge | 5 | May 25th, 2004 02:51 PM |
Mial merge data base problems | Rachael | Mailmerge | 16 | May 21st, 2004 06:22 PM |