|
|
|
other books
other books
|
Automated "Boilerplate"Autotext and AutoCorrect in Microsoft Word - including Building Blocksby Charles Kyle Kenyon, Esq. This page last edited Thursday 02 May 2013 - still a draft
There are no promises that this chapter is of the same quality and depth as the other chapters of this guide. That is because it was written by a single author not working with Microsoft. You will not find this chapter on the Microsoft site. Comments are welcome. What You Will LearnAfter completing this lesson, you will be able to:
Additional Written (and Web) Resources
Boilerplate Macro Package (Commercial Add Ins)
When I started using computer word processing the way to repeat text was with macros (even on paper tape!). I learned to write very lengthy and complex macros in Word Perfect. Macros are still useful in Word, but repeating boilerplate text is not a good use for them. Word has AutoText and AutoCorrect that do a much better job and are more easily edited. Distinguishing Among AutoText, AutoFormat and AutoCorrect (Overview and definitions)There are three "Auto" functions that are easily confused and work in similar ways when you are creating documents. Those are AutoText, AutoFormat, and AutoCorrect. AutoFormat and the related AutoFormat as you type are not useful for preparing boilerplate and may be discussed in depth elsewhere. You can turn functions on and off but you can't customize them. They don't insert text but can change how it looks dramatically. Both AutoText and AutoCorrect allow the user to pick text to be inserted. Both come with predefined replacements. They are stored in different places and are edited or transferred in different ways. Both can insert and replace text but they act and show up on your screen in different ways. AutoCorrect does what it name implies - fixes errors. It can do much more, though. It checks each "word" as you type by looking that "word" up in a database of corrections. Points to keep in mind:
The advantage of AutoCorrect is that it corrects errors in real time rather than coming back for correction later. A very real disadvantage is that what Microsoft considers an error may be a word you intend to use. If you use Google to search for "AutoCorrect fun" or "AutoCorrect errors" you'll likely find some entertaining examples. In Word, the most likely source of problems is checking the box at the bottom of the option to automatically use suggestions from the Spelling Checker.
Those suggestions will often be right, but when they are not, Word makes the substitution without telling you! For boilerplate, AutoText is usually superior to AutoCorrect because it is more easily edited and transferred from computer to computer. It resides in templates, rather than in a special file.
With AutoText if you type the first four letters of your AutoText entry name you'll see a tooltip showing the entire entry (or its start). If you press Enter when the tooltip is showing, you'll get your replacement entry. Especially in Word 2007-2010, if the tooltip is not showing but you've typed the first four letters, try pressing the F3 key. Note, if the first four letters are not unique to one AutoText entry, you'll need to type enough to have a unique entry name. You can also attach a keyboard shortcut to your AutoText entries, but that seems overkill. Either way you use AutoText you will probably find it useful. Continue using it and you will develop a whole library of boilerplate. In WordPerfect this function was filled with macros; in Word it is AutoText. While Word uses macros, they fulfill a different purpose. Where Are They?AutoText is kept in templates. It is stored in normal.dot by default but is often better kept in a document template or in a different global template. In Word 2007 and Word 2010 it is still stored in templates, but is a part of Building Blocks. In 2007/2010 AutoText entries are stored by default in a separate building blocks file but can be stored in other templates, including normal.dotm. See this article for the names and locations of the default building blocks files. AutoCorrect is mostly kept in separate files. Formatted AutoCorrect entries, though are stored in Normal.dot. (Normal.dotm in Word 2007/2010) More. AutoFormat is built into Word and switched on or off with options settings. See Tame AutoFormat. Assign Your AutoText Entries to a Key or Key CombinationThe following is taken from my response to someone on a newsgroup who wanted to assign keystrokes to superscripted numbers 1-4. She had asked to replace four of the symbols over the numbers on the keyboard with these and had been told by another (knowledgeable) user that this was not a good idea. Start Word. If you are already in Word, exit and restart it. Then, type five words in a new document. If you will only be using these in documents based upon a particular template, base your document on that template. If you want to be able to share these with someone else or move them to a different computer, you do not want to store them in Normal.dot. See Template Basics information on Global templates. Then insert the four superscripted numbers as if they were footnote references (that you were manually typing in rather than inserting footnotes). Then, in turn, select each of the superscripted characters and save them as AutoText entries named spr1, spr2, spr3 and spr4. (Insert => AutoText => AutoText) Make sure that the AutoText entries are being saved in the proper template if you are basing your documents on a special template. Then select the fifth word and assign it to autotext as spr5. Once you have the AutoText entries, you are ready to assign them to keys. The method we will use will replace only one of your keyboard's built-in key assignments for all five of the AutoText entries. (Word 97-2003) Tools => Customize => Keyboard (button)
Next repeat this process for your other four AutoText entries, typing the appropriate number for each. Then click on the close button and close the customize dialog box as well. Test your keys out. First press Alt-S. Nothing will seem to happen. Then type a 1. It will be superscripted. Type something else immediately after the 1. That should not be superscripted. Test each of your numbers. Finally, test it using the number 5. We put in this last entry so that you could see that it is indeed using your AutoText, not just altering the numbers that we happened to use as trigger keys. If you want, you can now go back into the AutoText dialog box and delete spr5. It has served its purpose. You could assign these autotext entries to any keystroke or keystroke combination (including the keys you originally requested). You should be very careful, though, about replacing key bindings because it can be very tricky to figure out what is going on when you forget about them (or if someone else tries to use your computer). You may have noted that you could use the Customize Keyboard dialog to assign not only AutoText but macros, styles, fonts, or any Word command to a key. You might want to copy these instructions to a text file called something like "Word key assignments.txt" and keep it, with any notes you care to make, so that you can backtrack later.
AutoText Keyboard Shortcuts Built into Word
Create a Custom Menu to hold your AutoText Entries (Word 97-2003)*There are (at least) two ways to do this, neither of which involve macros or VBA. The first method requires use of styles in both the creation and implementation of the AutoText entries. The second method require using the Customize... dialog under the Tools menu to create your menu. Once created, this menu works like any other Word menu. Both methods are demonstrated by the AutoText Sampler download. Both methods are intended for creation of a menu in a document template or global template; they will be used in your documents and templates. A custom Word menu is demonstrated in the Gender Toolbar template which has numerous fields saved as AutoText entries that are accessible from a custom menu. Use the AutoText Entries drop down box (built-in field) in your text as a fieldThis method involves use of Paragraph styles in both the creation and use of the AutoText. Unless a paragraph mark is a part of the AutoText entry, the style in which the entry is created will have no effect on the formatting of the inserted text. It will, however, change the category under which the entry is classified by Word. Creating your AutoText Entries so they will be placed in a category by Word.To create the entries for your list, type them in a document where they would normally be used. This document should be based on a template other than Normal.dot. Then select a potential grouping of text that you want to fit into a particular category. For this exercise, be sure that the text does not include a paragraph mark. Go to the Format menu and select Style... A dialog box will pop up with your current style selected. Unless you have already created a style for this kind of entry, click on the New button. This will pop up another dialog box for the creation of a new style. Give your new style a name, i.e., "z Interrogatories - AutoText." The "z" is in the name to put it at the end of most Styles lists; the "AutoText" tag is to indicate the style's function.
Click on OK to close the New Style dialog box. Note that we didn't make any changes to the style, nor did we check the box about saving it to the template, we just gave it a name. That name will become the AutoText category for entries of this type. Click on the Apply button so that your current entry will be formatted using this style. Then call up the AutoText dialog box. Tools menu -> AutoCorrect -> AutoText (tab) Change the box at the bottom so that it says: Look In: your template's name. What you want here is the name of the template on which your document is based, not "All available templates," or "Normal.dot." Click on the Add button to add your entry. Choose a name for your entry so that it will be clearly identifiable when you use it. (i.e., pid Expert - treating physician)
Then select the other text that you want to use for entries, one word, sentence or paragraph (without the paragraph mark) at a time. Change the paragraph style of each paragraph to that of your category style and add the autotext entry, each time checking to make sure that it is being saved in your template. At this point, close your document, without saving the changes to the document but saving changes to the attached template. You are now ready to create a drop down AutoText list based on the entries you just made. You can include paragraph marks in your AutoText entries but if you do this, your text in that paragraph will maintain its style. If the style already exists in the document, it will use the style definition already in place. If the style does not exist, it will be imported. See the IncludeText field tutorial for examples of the sorts of result you will get. Creating the drop-down AutoText listUse File -> New and create a new template based on the template to which you just added the AutoText. (Click radio button for "New Template" instead of "New Document" in the bottom-right corner of the dialog box.) (more to be written here) The text in teal which which follows is from the Word 2000 help screen on inserting a drop down field for AutoText:
See also How to add pop-up lists to any Word document, so you can click your way through changes in seconds by Bill Coan, MVP. * For Word 2007-2010 an easier way to categorize AutoText may be to put it in separate custom galleries. See Greg Maxey's site for more on this. Build your own custom menu(s) of AutoText entries by creating a toolbar
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| TO CREATE A LINE LIKE THIS | TYPE THIS AND PRESS ENTER | ||||
| --- (Three HYPHENS) | |||||
| ___ (Three UNDERSCORES) | |||||
| === (Three EQUAL SIGNS) | |||||
| ### (Three POUND SIGNS) | |||||
| *** (Three ASTERISKS) | |||||
| ~~~ (Three TILDES) | |||||
If you're having trouble making this tip work, try this:
Note: These can be very disconcerting if you don't know that this is what is happening. For that reason, many experienced Word users, including your author, turn this option off. If you want to not apply these (or any other AutoFormat or AutoCorrect) press Ctrl-Z immediately after Word makes the change. You can also add a space after your three (or more) characters and Word will not convert the characters to a paragraph border. If you are past the point where Ctrl-Z will help, you can get rid of one of these borders by removing the border format from the paragraph.
In Word 97-2003, place your cursor in the text line above the border and use Format => Borders and Shading. Make sure that the apply to box says "paragraph" and click on the box for "none."
In
Word 2007-2010, place your cursor in the text line above the border and
on the Home tab find the Borders and Shading dropdown in the paragraph group; it
will be highlighted (shown left). Select No Border.
Unformatted AutoCorrect entries are stored in .acl files. These files are language-specific. That is, if you change the language setting for your text, a different .acl file will be used (or generated).
Formatted AutoCorrect entries are stored in normal.dot.
See also
What Files Do I Need to Back Up?
This utility supplants and improves the utility from Microsoft. It
copies your AutoCorrect Entries into a Word table.
They can be viewed and edited in that table. Then the utility can put
your edits into your AutoCorrect all at once. You can also copy the
table to a different computer and use the utility to copy your AutoText
onto that computer. Easy to use. Free! The version of this
utility for Word 2007 and 2010 can be found on Jay Freedman's
site.
(The following is from the Chapter on Numbering:)
A Sequence field tracks differently numbered lists within a document. Combining Sequence fields and AutoText entries give you a fast and easy way to insert Interrogatories, Requests for Production, and Requests for Admission.
![]() |
Note The "Rog" in this example is the name of the Interrogatory numbering scheme. This name will keep this numbering scheme unique from any other schemes that may be running in the document. See Tip below for more information. |
To use the AutoText entry, simply type rog and press F3.
| Tip Follow the same steps (above) to create Request for Production or Request for Admissions. The only difference would be in Step 3, you would change the "rog" to "rpf" or "rfa". This will keep unique numbering schemes running in the same document. Therefore, you could have an Interrogatory No.1 as well as Request for Production No.1. Keep in mind that if you cut, copy or paste sequence codes, you'll need to select them and press F9 to update the field codes. They do not update automatically. |
You can print all AutoText entries (in the attached template and any global templates) using:
File > Print
In the print dialog box toward the lower left you will see "Print what" answered with "Document." Change that to "AutoText entries." Click on OK.
Use the AutoCorrect backup utility you can download from the MVP FAQ site to create a table with your AutoCorrect entries. Print that table.
Many of the AutoFormat as You Type Options cause unexpected changes in your document. While there are times when they are useful, those times are not frequent for your author. Here are screenshots showing the ones that I uncheck, and those that I leave on. These are from Word 2003 and Word 2010.

See Tame AutoFormat.
Weird formatting?
No tooltip is showing for my AutoText so I can't press Enter and insert it.
In Word 2010 this indicates that your AutoText is stored somewhere other than normal.dotm. This is perfectly acceptable but you can't use the Enter key or see the tooltip. Once you have typed at least four letters of the name, try pressing the F3 key to insert your AutoText. Long term, you can use the organizer to insert it.
In Word 2007 no tooltips show for AutoText entries. Period. You can still use the F3 key to enter AT entries in your text.
In Word 97-2003 this may indicate multiple AutoText entries with the same entry name or that you haven't typed enough of the name for Word to distinguish the entry you want from a different one with the same beginning to the name.
Missing Page Number / Header / Footer Commands - greyed out - Charles Kenyon
If AutoCorrect does something you don't like, immediately press Ctrl-Z to UnDo it. You can edit the AutoCorrect Options to remove entries that consistently cause you problems.
If AutoFormat as You Type causes you problems, immediately press Ctrl-Z to undo the change it made. Then go into the options to turn off the feature that is causing you problems. You can see at I keep most of the options off on my computer.
Check to see if automatic updating is turned on for the style. With automatic updating, a style is updated automatically when you make additional changes to the style, meaning that every paragraph in your document assigned to that style will change automatically. To turn off this feature, click the Format menu, and choose Style. Select the style in the Styles box, and then click Modify. If the Automatically update check box is selected, clear it.
Your style may have been based on another style that has changed. Changes to a base style affect other styles in the document that are based on it. For example, if you change the font in Normal to the Arial font, Word changes the font for the styles used in footnotes, headers, footers, page numbers, and other text. If you don't want a certain style to change when you change the base style, make certain your style is not based on another style. On the Format menu, click Style. In the Styles box, click the style you want to modify, click Modify, and then click (no style) in the Based on box.
![]() |
Warning When you base a style on No Style, you
will need to set the Language because the default will be No
Proofing.
(Word 97) Charles Kenyon note: I recommend that you not base any styles on normal and that you change the built-in styles so that they are not based on normal. This is particularly true for any styles that are involved in paragraph numbering. |
Charles Kenyon note: I recommend that you keep the Automatically update styles check box unchecked. Especially if you will be sharing your documents with others, leaving it checked can result in truly bizarre formatting and make your documents ugly or even unusable.
If the template that contains the style definitions is missing or damaged, styles in the current document use the style definitions from the Normal template.
Sometimes when you apply a style that has specific formatting
attributes to text already formatted this way, the reverse formatting may
occur. For example, when you apply a style that contains bold formatting
to a paragraph that contains some bold text, the bold text may lose its
bold formatting. This problem will not occur if you apply character
formatting— either through a character style or direct formatting — after
you apply a paragraph style. Apply the style first, and then select the
words to have other formatting and apply the formatting directly.
| Tip To make sure that no direct formatting has been applied to the text, first select the text completely and then press CTRL+SPACEBAR. This removes manually applied formatting. Now when a style is applied, there is no reversing situation to occur. |
Following is from Knowledge Base:
Article http://support.microsoft.com/support/kb/articles/Q170/7/26.ASP
WD97: Macros to Test for an Existing AutoText Entry Name |
Article: http://support.microsoft.com/support/kb/articles/Q176/6/92.ASP
WD: Creating Custom Date Formats with AutoText and/or Toolbar |
since 14 April 2004
|
|
Copyright 2000, Microsoft Corporation.
Copyright 2000-2002, 2004-2006, 2010-2013
Charles
Kyle Kenyon
See information about copy permission.
Search Intermediate Users Guide to Microsoft Word Using Google My office page as a Madison, Wisconsin Criminal Defense Lawyer.
|
|