Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.mailmerge.fields
jo jo is offline
external usenet poster
 
Posts: 2
Default IF field evaluating a bookmark yields incorrect result

I have a merge document with nested IF fields evaluating bookmarks.
The bookmarks are set at the beginning and ending of the document to
capture previous and current records for a directory merge. A
condensed version is as follows:

{ SET Place1 { MERGEFIELD VENDOR_NAME } { SET Place3 { MERGEFIELD
ITEM_NAME } }{SET Place5 {MERGEFIELD SWREPORTLABEL } { SET Place7
{ MERGEFIELD STD } }
{IF { Place2 } { Place1 } "{ MERGEFIELD VENDOR_NAME }" "" }
{IF { Place4 } { Place3 } "{ MERGEFIELD ITEM_NAME }" ""}
{IF { Place6 } { Place5 } "{ MERGEFIELD SWREPORTLABEL }" ""}
{IF { Place8 } { Place7 } "{ MERGEFIELD STD }" "" }
{MERGEFIELD BULLET_TEXT }
{ SET Place2 { MERGEFIELD VENDOR_NAME } { SET Place4 { MERGEFIELD
ITEM_NAME } }{SET Place6 {MERGEFIELD SWREPORTLABEL } { SET Place8
{ MERGEFIELD STD }}

At the level evaluating bookmarks Place8 and Place7, merged data is
incorrectly, but consistently for certain records, evaluated with the
true part of the IF statement (so there is no {MERGEFIELD STD}
repeated) when the bookmarked values are not equal.

Any ideas?

  #2   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Peter Jamieson Peter Jamieson is offline
external usenet poster
 
Posts: 4,582
Default IF field evaluating a bookmark yields incorrect result

Before doing anything else, can you please try quoting the bookmarks in the
IF statements (e.g.

change

{IF { Place2 } { Place1 } "{ MERGEFIELD VENDOR_NAME }" "" }

to

{ IF "{ Place2 }" "{ Place1 }" "{ MERGEFIELD VENDOR_NAME }" "" }


--
Peter Jamieson
http://tips.pjmsn.me.uk

"jo" wrote in message
...
I have a merge document with nested IF fields evaluating bookmarks.
The bookmarks are set at the beginning and ending of the document to
capture previous and current records for a directory merge. A
condensed version is as follows:

{ SET Place1 { MERGEFIELD VENDOR_NAME } { SET Place3 { MERGEFIELD
ITEM_NAME } }{SET Place5 {MERGEFIELD SWREPORTLABEL } { SET Place7
{ MERGEFIELD STD } }
{IF { Place2 } { Place1 } "{ MERGEFIELD VENDOR_NAME }" "" }
{IF { Place4 } { Place3 } "{ MERGEFIELD ITEM_NAME }" ""}
{IF { Place6 } { Place5 } "{ MERGEFIELD SWREPORTLABEL }" ""}
{IF { Place8 } { Place7 } "{ MERGEFIELD STD }" "" }
{MERGEFIELD BULLET_TEXT }
{ SET Place2 { MERGEFIELD VENDOR_NAME } { SET Place4 { MERGEFIELD
ITEM_NAME } }{SET Place6 {MERGEFIELD SWREPORTLABEL } { SET Place8
{ MERGEFIELD STD }}

At the level evaluating bookmarks Place8 and Place7, merged data is
incorrectly, but consistently for certain records, evaluated with the
true part of the IF statement (so there is no {MERGEFIELD STD}
repeated) when the bookmarked values are not equal.

Any ideas?


  #3   Report Post  
Posted to microsoft.public.word.mailmerge.fields
jo jo is offline
external usenet poster
 
Posts: 2
Default IF field evaluating a bookmark yields incorrect result

On Feb 5, 5:11*pm, "Peter Jamieson"
wrote:
Before doing anything else, can you please try quoting the bookmarks in the
IF statements (e.g.

change

{IF { Place2 } { Place1 } "{ MERGEFIELD VENDOR_NAME }" "" }

to

{ IF "{ Place2 }" "{ Place1 }" "{ MERGEFIELD VENDOR_NAME }" "" }

--
Peter Jamiesonhttp://tips.pjmsn.me.uk

"jo" wrote in message

...



I have a merge document with nested IF fields evaluating bookmarks.
The bookmarks are set at the beginning and ending of the document to
capture previous and current records for a directory merge. *A
condensed version is as follows:


{ SET Place1 { MERGEFIELD VENDOR_NAME } { SET Place3 { MERGEFIELD
ITEM_NAME } }{SET Place5 {MERGEFIELD SWREPORTLABEL } { SET Place7
{ MERGEFIELD STD } }
{IF { Place2 } { Place1 } "{ MERGEFIELD VENDOR_NAME }" "" }
{IF { Place4 } { Place3 } "{ MERGEFIELD ITEM_NAME }" ""}
{IF { Place6 } { Place5 } "{ MERGEFIELD SWREPORTLABEL }" ""}
{IF { Place8 } { Place7 } "{ MERGEFIELD STD }" "" }
{MERGEFIELD BULLET_TEXT }
{ SET Place2 { MERGEFIELD VENDOR_NAME } { SET Place4 { MERGEFIELD
ITEM_NAME } }{SET Place6 {MERGEFIELD SWREPORTLABEL } { SET Place8
{ MERGEFIELD STD }}


At the level evaluating bookmarks Place8 and Place7, merged data is
incorrectly, but consistently for certain records, evaluated with the
true part of the IF statement (so there is no {MERGEFIELD STD}
repeated) when the bookmarked values are not equal.


Any ideas?- Hide quoted text -


- Show quoted text -


It worked; amazing, something so simple...thanks!
Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Date form field incorrect result Wraithchilde Microsoft Word Help 3 January 19th 07 08:48 PM
Incorrect result from =count(above) billfalls Tables 1 March 5th 06 10:32 AM
Result in form field to generate comment in next field Phil Coates Microsoft Word Help 2 November 2nd 05 08:16 AM
Merged field yields scientific number okiebeancounter Mailmerge 3 September 23rd 05 12:16 AM
Incorrect backward link: destination bookmark - originating hyperl Eddie Thys Microsoft Word Help 0 May 19th 05 09:13 PM


All times are GMT +1. The time now is 09:47 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"