Drop Down Form Field in IF Field

B

brandon.lester

I have been trying to use a drop down form field to set the text in
another text form field, but have gotten many problems. My field code
is as follows: {IF {TapeOrientation} = "A" "TrueText" "FalseText" }

No matter what the TapeOrientation drop down form is set to,
"FalseText" is displayed. I tried everything mentioned in an older
posting
http://groups.google.com/group/micr...2183503ee14/cdacb44d3299dbd6#cdacb44d3299dbd6
and I would like to stay away from using a macro if possible.

Why is the correct code not working? Is there a setting I may need to
change?
 
S

Suzanne S. Barnhill

TapeOrientation is a bookmark, not a field. Try { IF { REF TapeOrientation }
= "A" "TrueText" "FalseText" }

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA

Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.
 
B

Brandon Lester

TapeOrientation is a bookmark, not a field. Try { IF { REF TapeOrientation }
= "A" "TrueText" "FalseText" }

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site:http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.






- Show quoted text -

I've read in previous posts that the REF prefix is not necessary. Even
when I insert it, the set up does not work. I've noticed that the IF
field syntax is sensitive to spaces and quote marks. Below are a
series of codes and outputs I get:

CODE 1: { IF { REF TapeOrientation } = "A" "TrueText" "FalseText" }
RESULT 1: "REF"

CODE 2: { IF {REF TapeOrientation} = "A" "TrueText" "FalseText" }
RESULT 2: "TapeOrientation}"

CODE 3: { IF {REFTapeOrientation} = "A" "TrueText" "FalseText" }
RESULT 3: "False Text"

Only the 3rd code gives something close to expected, but it is still
not the desired output, and I think it only gives "FalseText" because
the {REFTapeOrientation} is giving an error to the rest of the code.
Is it possible someone could attach a document with a working code
that I could open and try out on my computer?

Thanks!
 
S

Suzanne S. Barnhill

The document you sent had three problems:

1. The dropdown had no bookmark (so the REF field wasn't referring to it).

2. The REF field wasn't a field, just text with typed braces around it.

3. There were no other form fields in the document, so it wasn't possible to
tab out of the dropdown to update the REF fields.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA

Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top