+ Reply to Thread
Results 1 to 3 of 3

Trying to use the If field to see if bookmark contains a string of text

  1. #1
    Forum Expert Whizbang's Avatar
    Join Date
    08-05-2009
    Location
    Greenville, NH
    MS-Off Ver
    2010
    Posts
    1,395

    Trying to use the If field to see if bookmark contains a string of text

    I am looking for a way to use field codes to see if a Text Form Field contains a specific string, and if so, display some text.

    Specifically my Text Form Field is to gather the mailing address. If the mailing address is a PO Box, then I need to display a warning to also collect the physical address.

    So, I have { If {MailingAddr} = "PO Box" "Please also get the physical address" }

    But, the {MailingAddr} field will contain more than just "PO Box", so I need to add some wild cards ("PO Box*") or use some sort of other evaluation to do a partial match.
    Last edited by Whizbang; 08-21-2010 at 04:28 PM.

  2. #2
    Forum Expert contaminated's Avatar
    Join Date
    05-07-2009
    Location
    Baku, Azerbaijan
    MS-Off Ver
    Excel 2013
    Posts
    1,430

    Re: { If {TextFormField} CONTAINS "Text"... }

    I hope you'll be able to find the solution at Word MVP's site.
    Люди, питающие благие намерения, как раз и становятся чудовищами.

    Regards, ?Born in USSR?
    Vusal M Dadashev

    Baku, Azerbaijan

  3. #3
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: Trying to use the If field to see if bookmark contains a string of text

    Word does not have a function to extract parts of a field, nor does it have a "contains" comparison available to the IF function.

    You'll have to redesign your approach.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1