If Statement Always Resolves to False

  • Thread starter Thread starter Len Robichaud
  • Start date Start date
L

Len Robichaud

What am I doing wrong? The following always resolves to False.
{ ASK txtName "Enter Name" \*MERGEFORMAT }

{ REF txtName } 'Prints - Len



{ IF { REF txtName } = "Len" "Me" "Someone Else" } 'Prints - Someone Else



TIA

Len
 
Hi, Len,

I tried your fields here, and they work perfectly. What version of Word are
you using?

Since the REF txtName field is working for you, I would focus on a possible
error (typo) in the IF statement. Are you sure your IF statement is what you
included in this message?

See if you can get it to return ME for anything at all. For example:


{ IF "Len" = "Len" "Me" "Someone Else" }

Does that statement return ME for you? If not, then how about:

{ if "1" = "1" "Me" "Someone Else" }

Does that statement work? Once you get it working for anything all, work
fowards and see if you can find out where it breaks down. If all else fails,
feel free to send me a small document containing the fields, and I can take
a look to see if there's an error I can spot. Send to herb at herbtyson dot
com.
 
Back
Top