Solved

Formula in Word

Posted on 2016-09-26
5
25 Views
Last Modified: 2016-11-08
I need a formula that test the contents of the Tags field in Word.

Our firm has a line at the bottom of correspondence with reads
SPC:  via Certified Mail #1111 0000 0000 0000 0000 - Return Receipt Requested
or
SPC:  via Fedex Airbill #
or
SPC:  hand deliver or other language, but no numeric values.
or
the SPC line does not appear at all if the Tags field is blank.

Tags field in Properties will either have a number greater than 1000000000000000000 (Certified Mail)
greater than 100000000000 and less than 1000000000000000000 (Fedex)
or verbiage, if any, which should appear exactly as written
0
Comment
Question by:Bill Golden
  • 2
  • 2
5 Comments
 
LVL 76

Expert Comment

by:GrahamSkan
ID: 41815977
Is the Tags field a custom document property?

What sort of formula are you looking for - a test using Word Fields, VBA or something else?
0
 
LVL 1

Author Comment

by:Bill Golden
ID: 41817371
Tags is a standard field used by Word. It is in the Word properties section.

Previously, Word 2003, we used Word fields with an If Statement
0
 
LVL 1

Author Comment

by:Bill Golden
ID: 41817402
Currently, I have the following formula...

IF TAGS<1000000000000000000 "Fedex Airbill # "Tags"" "Certified Mail #"Tags" - Return Receipt Requested" \* MERGEFORMAT

I do not understand the nomenclature involved to get the value of Tags to print and my IF statement is not working.
0
 
LVL 76

Accepted Solution

by:
GrahamSkan earned 500 total points
ID: 41817765
Tags in that sense are data external to the Word document file., so copying the document doesn't copy the Tags.  They are seen in the document properties 'Keywords, so you would need to use the DOCPROPERTY field. The next condition would be nested in the False part of the previous condition.
{ IF {DOCPROPERTY Keywords} <  1000000000000000000 "Fedex Airbill # " { IF {DOCPROPERTY Keywords} >  100000000000 "Certified Mail" "...}}
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Excel Error per WinZip Add-In 9 59
How to convert JSON file to csv? 7 71
Microsoft Word - New Language Dictionary 2 47
copy the content of word to outlook 3 46
This article describes how to use the Send to Mail Recipient command. The instructions apply generally to Office 2007 and later versions, but Microsoft® Word 2013 was used for the specific steps and figures.  What is Send to Mail Recipient? Send…
This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
This video shows where to find the word count, how to display it, and what it breaks down to in Microsoft Word.
The view will learn how to download and install SIMTOOLS and FORMLIST into Excel, how to use SIMTOOLS to generate a Monte Carlo simulation of 30 sales calls, and how to calculate the conditional probability based on the results of the Monte Carlo …

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now