Take the Trouble Out of Tables by Customizing Shortcut Menus

This article may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist. To maintain the flow of the article, we've left these URLs in the text, but disabled the links.

Take the Trouble Out of Tables by Customizing Shortcut Menus

This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release. by Tracy L. Aardsma

Shortcut menus make it easy to access commonly used options when you're working on a document. A simple right-click brings up a shortcut menu that contains commands relating to the item you clicked on. Since these menus are designed to provide quick access to frequently used tools, odds are that you'll find what you need on a particular shortcut menu. Occasionally, however, you might need to use a command that isn't found in the default set of shortcut menu items.

For instance, the Select Cell, Select Column, Select Row and Select Table commands don't appear on any of Word's table shortcut menus. Selecting a row or column with your mouse is difficult enough--selecting an entire table with the mouse can make you want to pull your hair out. The alternative is to use the selection commands located in the Table menu. However, rooting around in the Table menu is tedious work that would be much easier to execute via a shortcut menu.

Fortunately, you can modify shortcut menus for tables and other Word objects to include commands you use on a regular basis. Though the process is a little different from customizing an ordinary menu, you'll be surprised how simple it is. In this article, we'll discuss how you can modify Word's shortcut menus. Then we'll walk through an example that shows you how to add cell, column, row and table selection commands to one of Word's table shortcut menus.

Shortcut menus at a glance

To modify an existing shortcut menu, you must access the Toolbars property sheet in the Customize dialog box. This property sheet contains a Shortcut Menus toolbar item, which you can use to modify any of Word's shortcut menus. The Shortcut Menus toolbar, shown in Figure A, contains three buttons: Text, Table and Draw. Each button reveals a submenu that lists the names of each corresponding shortcut menu. When you click on one of these names, the corresponding shortcut menu is displayed. For example, if you click Text in the Shortcut Menus toolbar and then select Fields from the resulting submenu, as shown in Figure B, Word displays a customizable version of the shortcut menu that's displayed when you right-click on a field in a Word document.

Figure A: You can modify shortcut menus via the Shortcut Menus toolbar.

Figure B: The Shortcut Menus toolbar provides access to customizable versions of Word's shortcut menus.

Once you've displayed the Shortcut Menus toolbar, you can use the Customize dialog box's Commands property sheet to modify any shortcut menu. In the Commands property sheet, first select the category that relates to the type of command you want to place on a shortcut menu. In response, Word displays a selection of corresponding items in the Commands list box.

When you locate the command you want to add to a shortcut menu, simply drag it from the Commands list box to a shortcut menu using the buttons on the Shortcut Menus toolbar. When you drag the command to the desired location on the menu, a horizontal line marks the spot where the command will land when you release the mouse button. In some cases, a shortcut menu item will have its own submenu, denoted by a solid black, right-pointing arrow. If you need to insert a command on a submenu, drag the command to the appropriate item to display its submenu. Then, drop the command where you want it to appear on the submenu. If you're adding a collection of related commands to the same shortcut menu, you can even create your own submenu in which to store them. We'll show you how later on in this article.

After you've added the command to a shortcut menu (or submenu), close the Customize dialog box to secure the changes. Note that unlike other toolbars that are selected in the Toolbars property sheet, this one disappears when you close the Customize dialog box. The next time you access the shortcut menu you modified, your custom command will appear where you placed it.

An example: Customizing Word's Table Text shortcut menu

To help you get accustomed to working with the Shortcut Menus toolbar, we'll show you how to add table selection commands to the Table Text shortcut menu shown in Figure C. This shortcut menu appears when you right-click on a table cell. Using the Shortcut Menus toolbar and the Commands property sheet, we'll first add a new submenu to Word's Table Text shortcut menu. Then, we'll add Word's collection of table selection commands to the new submenu.

Figure C: We'll add a submenu of table selection commands to this shortcut menu.

Creating a new submenu

Before we add new commands to the Table Text shortcut menu, we need to create a new submenu in which to store them. To begin, select Tools | Customize from the menu bar. Click on the Toolbars tab (if necessary) and then select the Shortcut Menus check box in the Toolbars list box. When you do, Word displays the Shortcut Menus toolbar.

To create a new submenu, click on the Commands tab in the Customize dialog box. Choose Normal.dot from the Save In dropdown list to ensure that your shortcut menu modifications are available with any document based on the Normal.dot template. Next, select New Menu in the Categories list box. In response, Word displays the New Menu command in the Commands list. Drag the New Menu item from the Commands list to the Table button on the Shortcut Menus toolbar, but don't drop it yet. When the Table button's submenu appears, drag the New Menu command to the Table Text item. When the customizable Table Text shortcut menu appears, drop the New Menu item beneath the Merge/Split Cells command, as shown in Figure D.

Figure D: We'll store our table selection commands in this new submenu.

Before you add commands to your new submenu, let's give it a more meaningful name. Right-click on the New Menu item you just created. In the resulting shortcut menu, change the Name property from New Menu to Select, then press [Enter].

Adding the selection commands to the shortcut menu's submenu

Now that you've created a submenu in which to store your table selection commands, let's fill it up! The cell, column, row and table selection commands we'll add to our new submenu are listed and described in Table A. Oddly, you won't find them listed in the Table category in the Commands property sheet. Instead, you'll need to locate them in the All Commands category. Once you've located the commands, you simply drag them to the submenu you added to the Table Text shortcut menu using the procedure we described earlier in this article.

Table A: Table selection commands

Command Description
TableSelectCell Selects the table cell that contains the insertion point
TableSelectColumn Selects the table column that contains the insertion point
TableSelectRow Selects the table row that contains the insertion point
TableSelectTable Selects the table that contains the insertion point

To begin, in the Customize dialog box's Commands property sheet, select the All Commands item in the Categories list box. Next, scroll through the Commands list until you find the commands listed in Table A. You can locate these commands more quickly if you first click in the Commands list and then press the T key. This action jumps you to the commands that begin with the letter T. Keep scrolling from here until you find the commands listed in Table A.

The first of the selection commands you'll see is the TableSelectCell command. To add the table selection commands to the Select submenu you created in the Table Text shortcut menu, drag each one from the Commands list to the Select submenu that stems from the Shortcut Menus toolbar. When you drop each command in the Select submenu, it takes on a menu-friendly name; for instance, the TableSelectCell command uses the shortcut menu name Select Cell. Repeat this process with the remaining commands listed in Table A. When you've finished, the submenu should resemble Figure E. To wrap up the process and return to your document, click the Close button in the Customize dialog box.

Figure E: We added a new submenu containing table selection commands to the Table Text shortcut menu for easier access.

Testing the customized shortcut menu

To make sure that your commands landed where you intended them to, insert a new table in your document by clicking the Insert Table button on the Standard toolbar and selecting any number of rows and columns. Now, right-click on any table cell. When you do, Word displays the modified version of the Table Text shortcut menu--complete with the Select submenu and the commands you added--as shown in Figure F.

Figure F: Our new selection commands streamline table manipulation.

A note about context

Word's shortcut menus have become so specialized that it's important to determine exactly which shortcut menu you want to modify before you begin. Otherwise, you could wind up with a command that doesn't function in a given situation or that doesn't appear on the shortcut menu you thought it would.

For instance, we added the table selection commands to the Table Text menu because this menu appears when you right-click in a table cell, which is easy to remember. However, if you right-click on a selected table cell, Word displays the Table Cell shortcut menu instead and none of your table selection commands. And, if you right-click on a cell that contains a numbered list, Word displays the Table Lists shortcut menu, and again none of your custom selection commands. The specialized nature of shortcut menus ordinarily works to your advantage, but if you want a command to be available in a variety of situations, be sure to place it on all shortcut menus that you're bound to want to access it from.

If you want to modify a shortcut menu for a template other than Word's global template, Normal.dot, you'll need to begin the process by activating a document that's attached to that template (or the template itself). Before you make any modifications in the Customize dialog box, select the template name from the Save In dropdown list that appears in the Commands property sheet. Saving your modifications in a specific template confines your changes to documents that are attached to that template.

Reversing your changes

If you decide that you want to revert to the default set of commands on a shortcut menu, you can take a couple of routes. One approach removes all the modifications to all the shortcut menus in the active template. The other method allows you to remove a specific command from an individual shortcut menu.

Resetting all shortcut menus

To reset all the shortcut menus, first choose Tools | Customize from the menu bar and then click on the Toolbars tab (if necessary). Next, select Shortcut Menus from the Toolbars list. (You don't need to select the check box--simply select the item name.) Finally, click Reset. When you do, Word displays the Reset Toolbar dialog box and prompts you to choose which document or template you'd like to reset. Select the document or template whose shortcut menus you'd like to restore, then click OK to reset all the shortcut menus to their default state. When you've finished, click Close to dismiss the Customize dialog box.

Removing individual commands

Removing an individual command from a shortcut menu is equally straightforward. Begin by opening the Customize dialog box, clicking on the Toolbars tab, and selecting the Shortcut Menus check box to display the Shortcut Menus toolbar. Then, display the menu you want to modify using the Shortcut Menus toolbar. Click on the command you want to remove and then just drag it off the menu. Incidentally, you can drag Word's default commands off a shortcut menu in this fashion--and get them back again by resetting all your shortcut menus as previously described. However, keep in mind that once you remove an item you've placed on a shortcut menu, resetting won't restore that item. Instead, you'll need to place the custom command back on the menu yourself.

Conclusion

Though Word's shortcut menus are designed to offer quick access to frequently used commands, they aren't always as intuitive as you might hope they'd be. Fortunately, you can easily modify Word's shortcut menus to your liking using the Customize dialog box and the Shortcut Menus toolbar. In this article, we've shown you one way to improve access to Word's table selection commands using custom shortcut menu commands. However, you can use this simple technique to enhance any of Word's specialized shortcut menus. Where, oh where, will you begin?

Copyright © 2000 Element K Content LLC. All rights reserved. Reproduction in whole or in part in any form or medium without express written permission of Element K Content LLC is prohibited. Element K is a service mark of Element K LLC.