Top Navigational Bar

Glossary Macro for Expanding Abbreviations
DocumentID: 603947
Revision Date: 29-Feb-96 1:30:27 PM

The information in this document applies to:
WordPerfect® 5.1 for DOS

Problem

Symptoms: The customer wants to be able to expand predefined abbreviations to their full form. For example, "wpc" could be automatically expanded to "WordPerfect Corporation." Solutions: This feature is available on the MACROS keyboard and is assigned to Ctrl-G. The macro examines the word the cursor is immediately after and looks for a defined abbreviation. If one is found, the abbreviation will be replaced with the expanded text.

To define an abbreviation, edit Ctrl-G by doing the following:
1.      Press Shift-F1 for Setup
2.      Press 5 for Keyboard Layout
3.      Highlight the MACROS keyboard
4.      Press 7 for Edit
5.      Highlight Ctrl-G
6.      Press 1 for Action
7.      Move the cursor to the end of the macro editor
8.      Add the commands for each abbreviation desired
      a.      First line
            {LABEL} followed by the abbreviation and a tilde
            Example: {LABEL}asap~
      b.      Second line
            The full form you wish the abbreviation to be replaced with
      c.      Third line
            {RETURN}
9.       Press F7 for Exit twice
10.      Make sure the MACROS keyboard is highlighted and press 1 for Select
11.      Press F7 for Exit
12.      Type the abbreviation, position the cursor after the abbreviation, and press Ctrl-G

The abbreviation will then be replaced with the full form of the word.

The original Glossary macro may fill up. In this case the customer may want to create another macro that the first Glossary macro will chain to using the following steps:
1.      From a clear screen press Shift-F1, 5, highlight the MACROS keyboard, and press 7 to Edit
2.      Cursor to Ctrl-G, press 6 to Save, type GLOS1, and press Enter (This will be the original Glossary macro with all of the customer's changes to it)
3.      With Ctrl-G still highlighted, press 6 to Save, type GLOS2, and press Enter
4.      With Ctrl-G still highlighted, press 6 to Save, type a name (this macro will be the backup in case you or the customer makes a mistake), and press Enter
5.      Press F7 twice to return to the document screen
6.      To edit the macros press Ctrl-F10, type GLOS1, press Enter, and select 2 for Edit
7.      Change the third line in the macro from {ON ERROR}{CALL}restore~~ to {ON ERROR}{CALL}test~~
8.      Press Home, Home, Down Arrow to move to the bottom of the macro
9.      Insert the following lines:
      {LABEL}test~
      {Cancel}1
      {CHAIN}glos2~
10.      Press F7 once to save the macro
11.      Press Ctrl-F10, type GLOS2, press Enter, and type 2 to Edit
12.      Cursor past the Restore label ({LABEL}restore~
                                           {Cancel}1
                                           {RETURN})
13.      Delete all of the information after the {RETURN} command
14.      Add additional abbreviations as needed

Answer:

Details:


Product specifications, packaging, technical support and information (*Specifications*) refer to theUnited States retail English version only. Specifications for other versions may vary. All Specifications, claims, features, representations, and/or comparisons provided are correct to the best of our knowledge of the date of publication, but are subject to change without notice.OUR MAXIMUM AGGREGATE LIABILITY TO YOU AND THAT OF OUR DEALERS AND SUPPLIERS IS LIMITED. IT SHALL NOTEXCEED THE AMOUNT YOU PAID TO ACCESS THE INFORMATION. SEE LEGAL DISCLAIMER.