Graham Mayor

... helping to ease the lives of Microsoft Word users.

Many people access the material from this web site daily. Most just take what they want and run. That's OK, provided they are not selling on the material as their own; however if your productivity gains from the material you have used, a donation from the money you have saved would help to ensure the continued availability of this resource. Click the appropriate button above to access PayPal.

Word Variables, Bookmarks and Properties editor add-in for Word 2007 - 2016

The following came as a result of a discussion with friend and former Word MVP Greg Maxey about a convenient method of determining the presence and value of any docvariables in the current document, and, like many projects we have started together, it sort of grew like Topsy into the current offering on Greg's site.

However I feel that while this is a powerful tool, which was formerly also hosted on this page, it has got away from the original design concept, which was for a tool that not only displays the names and values of any docvariables present, but provides the opportunity to edit their content and insert docvariable fields into the document at the current cursor position to display the stored content.

So I took a step backwards and redeveloped one of the much earlier iterations, which I feel comes much closer to that design concept and additionally provides simultaneous access not only to Document Variables, but to Bookmarks and Document Properties, providing a means to create, edit and insert such items in the document.

Unlike the tool now hosted only on Greg's site, this one does not cater for Content Controls. Greg has done much research in that area and has an additional tool that should be investigated if working with content controls.

Variables, Bookmarks and Properties editor

Some of the built-in document properties, which this application can access, are not editable, but their values may be viewed and inserted, and some may only be inserted as content controls. The add-in caters for all these factors.

Where a function is not available for a given item or document, either the button which controls the function is disabled or the user is presented with an error message.

The functions have been designed to be self-evident, but there is a link to this page by clicking the GM logo on the main display.

Extract the template from the ZIP file to your Word startup folder with Word closed. If you have not changed the preferred startup folder it can be located (in English language versions of Windows) by typing

%appdata%\Microsoft\Word\Startup

in the Windows Explorer Address bar and pressing Enter.

The ZIP file also includes an EXE installer. This will automatically install the add-in to the default Word Startup folder (or can be redirected if you have changed that location) and will remove any previous version from that folder.

The add-in places a button  on the Insert Tab of the ribbon

When first run, the add-in will display the usual disclaimer. Future display of this disclaimer is controlled by a check box on the main window which follows.

On clicking the main button, the userform will display the 'Lists' tabbed page of the dialog which features various list boxes and an assortment of action buttons.

The userform will remain on screen until dismissed and is modeless, which means that you can switch to edit the document without dismissing the form.

If one or other docvariables, bookmarks or custom document properties are not present, the associated list box will display a message to that effect. There will however always be built-in document properties present and thus listed.

The action buttons beneath the lists are context sensitive and some examples are shown below:

Note that if a single item is selected in any of the four lists, a cross reference may also be inserted by double clicking that item.

Create a new Variable, Custom Property or Bookmark

Bookmarks are created using Word's own bookmarks function, Variables and Custom Properties may be created directly from the following page of the main dialog.

Built-in doc properties.

Note that the values of some built-in docproperties, such as the 'Company' item displayed, are user editable. Others reflect values created by the document and thus are not editable, though reference may be made to them in the document.

Protected Forms

This editor is not intended and not recommended to be used to complete Word protected forms, however it can be used to do so, and in particular it adds the ability to add list items to a dropdown form field - even in a password protected form, which cannot be normally achieved from Word while the form is protected. It does not provide the ability to add or delete form fields in a protected form, nor to change their properties.

Delete Items

Deletion provides the opportunity to unlink any cross references (retaining their content at the time) or to delete the cross references of individually selected items. In the case of bookmarks, there is also the opportunity to delete the bookmarked content.

Selection of items in any of the user editable lists also enables the Delete All action button which allows the items to be deleted from the list, but does not affect any cross references, which may thus show errors relating to the missing sources.

 

  - Click here to download the add-in

 

 

Word Variables

Word does not provide a convenient method of examining document variables, which thus tends to limit their usefulness to those who are comfortable with vba programming. Document variables are however extremely useful and can be used to store all manner of information to employ in in a document or macros used with that document.