Logo: TechTrax...brought to you by MouseTrax Computing Solutions

Creating Custom Toolbars for Templates

by Jonathan West, MVP

So, you’ve taken heed of all the articles in TechTrax telling you to create templates using styles, you have created some nice templates, the layout is beautiful, and you’ve tested your templates, and the styles all work.

Now you are planning to distribute the templates to your colleagues, and you need to get them to understand which styles they should use and which they shouldn’t. Word has an awful lot of built-in styles, and most documents will only need to use a very small number of them.

I find that with a simple letterhead template, there are only about 7 styles needed for the body of the document (Address, Subject, Body Text, Bullet list 1, Bullet List 2, Numbered List, Signature). Some documents might need rather more, I normally define about 25-30 styles in a complex report. Word has about 100 built-in styles available to every document. How do you encourage users to use your 7 or 25 styles, and not all the others?

Toolbars!

Word is designed to be customised. So let’s customise it! First thing you can do is add your own toolbar to your template, and put a button on it for each style you have defined.

(The following techniques and screenshots use Word 2000, which still seems to be the version of Word in most common use, but the technique is almost exactly the same in the other versions of Word.)

First of all, go to Tools > Customize, and the following Customize dialog will appear. Make sure the Toolbars tab is selected.

Click the New button to create a new toolbar. The following dialog appears.

You will want to change the toolbar name to something descriptive, as the toolbar’s name is also its caption if you decide to have the toolbar floating rather than docked (more on this later). Since we are going to be putting styles on the toolbar, call it Styles.

Also, you need to change the Make toolbar available to option. The toolbar is going to be distributed as part of your template, so it has to be stored there. Select your template from the dropdown list. If it isn’t there, then make sure that your template is open and is the active document, and then try again.

When you click OK, the Customize dialog will now show the styles toolbar, and a blank toolbar will be displayed floating somewhere near the dialog, as shown below.

The next step is to start putting buttons on the toolbar.

Click the Commands tab of the dialog, and then scroll down to and select Styles. A list of styles will be displayed in the right pane of the dialog.

What you now do is select each style you want, and drag it to the toolbar. After you drag the first one, the button on the toolbar will look something like this.

If you have several buttons, having the full name of the style is going to cause the toolbar to be rather large. But you can edit the button. Right-click on the button, and on the popup menu that appears, edit the button’s Name. For body text, maybe abbreviate it to BT. Repeat the process for each of your styles, and you will end up with a toolbar that looks something like this.

You now have a choice as to where the toolbar will appear when a document based on the template is created or opened. Broadly you have two choices—floating or docked.

If you want the toolbar to float, click on the blue title area of the toolbar, and drag it to some convenient area of the screen where it won’t hide any text.

If you want the toolbar to be docked, then you can drag it the toolbar area at the top of the screen, where it will take its place alongside the other toolbars already there. You can also drag the toolbar to the side or the bottom of the screen, if you want it there.

Then you save the template, and hand it round to your colleagues. Training them to use it is simple, you just tell them “See that toolbar there? Use that for your formatting, and apart from an individual word you want bold or underlined, you don’t use anything else!” OK, you also explain how to position the cursor in a paragraph and then click the appropriate button, and what the different styles are for, but training shouldn’t take more than a few minutes.

Further Discouragement of Bad Formatting

Just as you can customise Word by adding your own toolbar, you can also customise the standard toolbars to discourage people from using non-standard features. With your template open, go to Tools > Customise again, and set Save in to be your template instead of normal.dot. Now, any toolbar button or menu item can be removed by clicking on it and dragging it off its toolbar or menu. When the mouse pointer shows an X, you can let go of the mouse button, and the toolbar button or menu item is deleted.

Again, when you have finished, you save the template, so that the modified toolbars are available when a document based on the template is next opened or closed. By saving the changes in your template, it is only when documents based on your template are opened that the toolbars are modified.

Note that this is an ease-of-use measure rather than a security measure. If somebody is intent on using features you want to discourage, this will not prevent them from putting the buttons right back where they were. Hopefully, your template will be so easy to use that everybody will be happy with the changes.

Word 2003—Document Protection Feature

If your organisation has moved to Word 2003, then you can do all of the above, but in addition, you can physically prevent non-standard styles from being applied. The Word 2003 document protection feature is a huge advance on previous versions of Word in its power and flexibility, and by itself is a very good reason to upgrade to Office 2003 if your organization needs to have a controlled layout for the documentation produced by everybody in the organization.

With your template open, go to the Tools menu, and select Protect Document. The Protect Document Task Pane will appear on the right-hand side of the screen, looking like this.

Check the Limit formatting to a selection of styles box, and then click the Settings link. The Formatting Restrictions dialog will appear, as shown below.

In this dialog, you uncheck all the styles you don’t want your users to use in the body of the document. It will probably be simpler to click the None button first, and then select just your set of styles.Once you have selected your set of styles, click OK.

If your document contains extra styles which the user should not use in the body of the document (e.g. special styles for the header or for the cover page), then the message box below will appear warning you that the document may contain formatting or styles that are not allowed.

If you have defined extra styles, you don’t want them deleted, so you should select No.

Now you are ready to turn the protection on. On the task pane, there is a button titled Yes, Start Enforcing Protection. Click it, and the Start Enforcing Protection password dialog box will appear.

You will probably want a password to protect the template and its styles restriction, so type the password in twice as indicated, and press OK.

This kind of protection not only prevents non-standard styles from being applied, it also prevents all manual formatting from being applied. So if you want to allow people to make individual words bold or underlined, then you will need to define a character style for that, and add it to the list of acceptable styles, and define a button for it. Maybe also a keyboard shortcut.

 

Go up to the top of this page.
This site powered by the Logical Web Publisher™: Content management by Logical Expressions, Inc.