Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
range of merge fields?
I'm pretty sure the answer is already no, but I thought I'd ask...
I have logic to insert into a REALLY big merge. A particular indicator may appear in one of ten fields that would mean a mismatch in the type of letter being sent (we're accounting for the chance of human error). If a mismatch is found, I'm including a big line of text to alert staff not to mail the letter. I have this: {if {mergefield evaluationcd11}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd12}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd13}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd14}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd15}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd16}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd17}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd18}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd19}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd110}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} I don't suppose it's possible to say mergefields 11 through 110 without needing all of those if statements, is it? The 'FN' code would only be in one field, but not regularly in, say, cd11 or cd 12. Thanks in advance for any advice...go live is in two weeks and counting! Heather |
#2
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
range of merge fields?
I would suggest that you do the validation on the data source before the
merge. -- 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 "Heather" wrote in message s.com... I'm pretty sure the answer is already no, but I thought I'd ask... I have logic to insert into a REALLY big merge. A particular indicator may appear in one of ten fields that would mean a mismatch in the type of letter being sent (we're accounting for the chance of human error). If a mismatch is found, I'm including a big line of text to alert staff not to mail the letter. I have this: {if {mergefield evaluationcd11}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd12}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd13}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd14}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd15}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd16}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd17}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd18}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd19}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} {if {mergefield evaluationcd110}="FN" {includetext c:\\master_comment.doc letter_type_mismatch}""} I don't suppose it's possible to say mergefields 11 through 110 without needing all of those if statements, is it? The 'FN' code would only be in one field, but not regularly in, say, cd11 or cd 12. Thanks in advance for any advice...go live is in two weeks and counting! Heather |
#3
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
range of merge fields?
Yes, that would be the easy thing to do, wouldn't it?
Unfortunately, I'm looking at about 1700 columns of data per individual record, and it's difficult to edit the csv file (don't have excel 2007 and looking at it in a text editor is pretty rough). We'll be getting daily runs with about 100-300 records to print for about nine months of the year. Oh, well! Thanks for the suggestion! Heather Doug Robbins - Word MVP wrote: I would suggest that you do the validation on the data source before the merge. -- Hope this helps. Please reply to the newsgroup unless you wish to avail yourself of my services on a paid consulting basis. |
#4
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
range of merge fields?
In that case, I think you are stuck with the If field construction.
Something else that you might consider however is getting the program that creates the CSV file to replace 1 instead of FN and 0 for the not FN case, or opening the .CSV file and using edit replace to replace FN with 1 and not FN with 0 and then use an If field construction on an {= } field that added all of the mergefields that you want to test together so that if the total was 0 you the { includetext } would be inserted. -- 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 "Heather" wrote in message oups.com... Yes, that would be the easy thing to do, wouldn't it? Unfortunately, I'm looking at about 1700 columns of data per individual record, and it's difficult to edit the csv file (don't have excel 2007 and looking at it in a text editor is pretty rough). We'll be getting daily runs with about 100-300 records to print for about nine months of the year. Oh, well! Thanks for the suggestion! Heather Doug Robbins - Word MVP wrote: I would suggest that you do the validation on the data source before the merge. -- Hope this helps. Please reply to the newsgroup unless you wish to avail yourself of my services on a paid consulting basis. |
#5
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
range of merge fields?
There's an idea...maybe after the go-live for the software is
completed. Thanks for the tip! Heather Doug Robbins - Word MVP wrote: In that case, I think you are stuck with the If field construction. Something else that you might consider however is getting the program that creates the CSV file to replace 1 instead of FN and 0 for the not FN case, or opening the .CSV file and using edit replace to replace FN with 1 and not FN with 0 and then use an If field construction on an {= } field that added all of the mergefields that you want to test together so that if the total was 0 you the { includetext } would be inserted. |
#6
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
range of merge fields?
You can do something very much like that already using calculations in
fields without changing the value - see the section Testing for a value in one of several fields. at http://www.gmayor.com/formatting_word_fields.htm -- Graham Mayor - Word MVP My web site www.gmayor.com Word MVP web site http://word.mvps.org Heather wrote: There's an idea...maybe after the go-live for the software is completed. Thanks for the tip! Heather Doug Robbins - Word MVP wrote: In that case, I think you are stuck with the If field construction. Something else that you might consider however is getting the program that creates the CSV file to replace 1 instead of FN and 0 for the not FN case, or opening the .CSV file and using edit replace to replace FN with 1 and not FN with 0 and then use an If field construction on an {= } field that added all of the mergefields that you want to test together so that if the total was 0 you the { includetext } would be inserted. |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
A Merge letter requiring one or more different different mege letters depending on entry in fields | Microsoft Word Help | |||
Mail merge and blank fields | Mailmerge | |||
mail merge and text form fields | Mailmerge | |||
Inserting Merge Fields | Microsoft Word Help | |||
ASK and FILLIN fields in INCLUDETEXT documents do not merge correc | Mailmerge |