Results 1 to 3 of 3

Thread: IF Field

  1. #1
    3 Star Lounger
    Join Date
    Jan 2001
    Location
    Christchurch, New Zealand
    Posts
    250
    Thanks
    1
    Thanked 0 Times in 0 Posts

    IF Field

    IF fields seem quite simple but I do have problems when I am trying to print a slash . For example this works:

    {IF {KEYWORDS} <> "" "-" ""} with the true result
    KEYWORD TEXT-

    However, this doesn't work:
    {IF {KEYWORDS} <> "" "" ""} I get the result:

    KEYWORD TEXT" (with a space at the end)

    The must mean something, but I must be able to display it literally as well.

    The second one is the one I would prefer to use. Any ideas?

  2. #2
    Silver Lounger Charles Kenyon's Avatar
    Join Date
    Jan 2001
    Location
    Sun Prairie, Wisconsin, Wisconsin, USA
    Posts
    2,049
    Thanks
    124
    Thanked 119 Times in 116 Posts

    Re: IF Field

    Hi Karen,

    I'm not sure what it is you are trying to get (the formatting of these messages sometimes leaves a bit to be desired). A problem with the backslash () is that it is a special character, as is the quotation mark.

    { IF x <> "a" "-" "" } is my reading of your first. If x is anything other than "a" then your result is "-." If x is "a" then you get nothing. You want it to be a backslash.

    Try using two backslashes in a row (). This tells Word (for some unknown reason) that you really do want a backslash. Hope this helps.
    Charles Kyle Kenyon
    Madison, Wisconsin

  3. #3
    3 Star Lounger
    Join Date
    Jan 2001
    Location
    Christchurch, New Zealand
    Posts
    250
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: IF Field

    Thank you very much Chas - it works!!

    From memory this is similar to Access - when you use the the next character becomes a literal string.

    I love these forums!! <img src=/S/love.gif border=0 alt=love width=15 height=15>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •