OK, so you have two checkboxes (CheckA & CheckB) and four bookmarks (Check1, Check2, Check3 & Check4).
Using the solution I provided in my last post:
1. CheckA references Check1 when unchecked and Check2 when checked; and
2. CheckB references Check3 when unchecked and Check4 when checked.
You want to invert the behaviour. There are at least four ways of doing this that come to mind. Using the solution I provided in my last post, you could either:
1. swap the bookmarks around in the source document, so that -
• Check1 applies to what Check2 now applies to, and vice versa; and
• Check3 applies to what Check4 now applies to, and vice versa; or
2. modify the macros so that -
• .FormFields("Check1").Result + 1 becomes 2 - .FormFields("Check1").Result; and
• .FormFields("Check2").Result + 3 becomes 4 - .FormFields("Check2").Result; or
3. modify the source document and modify the macros thus:
• add an empty bookmark named Check 0 to the source document;
• change '.FormFields("Check1").Result + 1' to '.FormFields("Check1").Result'; and
• change '.FormFields("Check2").Result + 3' to '.FormFields("Check2").Result +2'; or
4. modify the source document and modify the macros thus:
• add an empty bookmark named Check 0 to the source document;
• re-assign the Check2 bookmark to range now spanned by Check4;
• delete the Check3 & Check4 bookmarks; and
• change '.FormFields("Check1").Result + 1' to '.FormFields("Check1").Result * 1'; and
• change '.FormFields("Check2").Result + 3' to '.FormFields("Check2").Result * 2'.
The reason I refer to the solution I provided in my last post is that, in your attachment, you've edited the macros so that both refer to their formfield result '+ 2', which means their INCLUDETEXT fields point to the same boomarks in the source document...
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
|