Resting Anchor

The Anchorage

Personal website of Gregory K. Maxey, Commander USN (Retired)

Content Control Custom Checkboxes
(A Microsoft Word Help & Tip page by Gregory K. Maxey)

DISCLAIMER/TERMS OF USE

The information, illustrations and code contained in my "Microsoft Word Tips" are provided free and without risk or obligation.

Click to acces PayPal Verification Service Click to acces PayPal Verification Service

However, the work is mine. If you use it for commercial purposes or benefit from my efforts through income earned or time saved then a donation, however small, will help to ensure the continued availability of this resource.

If you would like to donate, please use the appropriate donate button to access PayPal. Thank you!

Click to donate British Pound Sterling                   Click to donate US dollars                   Click to donate EU euros

This Microsoft Word Tips & Microsoft Word Help page provides a Word2007 template add-in that you can use to insert custom Content Control checkboxes in your Word2007 documents.

For unknown reasons, and to the sore disappointment of many users, Microsoft decided to not include a "Checkbox" control in the new collection of Content Controls available in Word2007 documents. However, with the use of AutoText, QuickParts, bookmarks, and a few macros we can:

The illustration below shows an example questionnaire with a series of grouped checkboxes.

cc custom checkboxe 1

Site Note IconNote: The light grey brackets are non-printing characters that represent the boundary of the bookmarks used to group the checkboxes.

The checked and un-checked boxes contained in the Content Controls are the displayed results of one of two MacroButton fields that are stored as AutoText in the template. The symbols themselves are taken from the "Wingdings" character set. The following illustrates the field code for each of these fields.

cc_custom_checkboxes_2

The macro procedures called by the MacroButton fields toggle the displayed symbol in the Content Control between a "Checked" or “Unchecked" box by replacing the current AutoText entry at the selection with its counterpart.

You can combine multiple checkboxes that function independently with group checkboxes in the same document. Your groups can be as small as two Content Controls to as many as you want.

The Check procedure also determines the ID of the current Content Control. This information is passed to another procedure to ensure that all other Content Controls in the same group display the unchecked box. As shown in the two illustrations below, bookmarks are used to define the individual groups of checkboxes in a document.

Site Note IconNotes:
     1. When selecting Content Controls for grouping you "MUST" include a trailing space or character that is "OUTSIDE" the range of and adjacent to the final Content Control in the group.

     2. You must use sequentially numbered bookmarks in the form "CheckGroup"1 as shown below. If you delete a group it is important that you check to ensure that your remaining groups are bookmarked sequentially starting with CheckGroup1.

cc_custom_checkboxes_3

cc custom checkboxes 4

Wait there is more! The add-in creates a new "Custom Content Controls" group to the Developer Tab. As you can see, there are also features for adding "X" boxes, Radio buttons, and even Mode buttons that will change from happy to sad.

Site Note IconNote: Groups must contain like controls. You can not define a group that is a mix of control types.

Clicking on any of these controls adds the corresponding Content Control at the insertion point. With a little effort, this AddIn could be modified to include practically any number of symbol pairs.

cc custom checkboxes 5

That's it! I hope you have found this tips page useful and informative. The add-in with the complete RibbonX and VBA code is provided here in a zip file format: Custom Content Control Checkboxes.

Site Note icon For more on template add-ins and how to load them, see: Organizing Your Macros/Template Add-ins at: Installing Macros

Share

DISCLAIMER/TERMS OF USE

The information, illustrations and code contained in my "Microsoft Word Tips" are provided free and without risk or obligation.

Click to acces PayPal Verification Service Click to acces PayPal Verification Service

However, the work is mine. If you use it for commercial purposes or benefit from my efforts through income earned or time saved then a donation, however small, will help to ensure the continued availability of this resource.

If you would like to donate, please use the appropriate donate button to access PayPal. Thank you!

Click to donate British Pound Sterling                   Click to donate US dollars                   Click to donate EU euros

Search my site or the web using Google Search Engine

Google Search Logo