Modifying the Format of TO: and CC: Lines in MEMO2.DOT

Last reviewed: July 30, 1997
Article ID: Q95065
The information in this article applies to:
  • Microsoft Word for Windows, versions 2.0, 2.0a, 2.0a-CD, 2.0b, 2.0c

SUMMARY

This article describes how you can modify the MEMO2.DOT template supplied with Word for Windows so it inserts each name on the TO: and CC: lines of a memo on a separate line, as shown below:

   TO: Bob Hawley
       Ed Paulson
       Steve Vaughan

   CC: Don Ellis
       Mark Gibson
       Susan Dodd

Note: Microsoft does not support modifications to the template files supplied with Word for Windows.

WARNING: ANY USE BY YOU OF THE CODE PROVIDED IN THIS ARTICLE IS AT YOUR OWN RISK. Microsoft provides this macro code "as is" without warranty of any kind, either express or implied, including but not limited to the implied warranties of merchantability and/or fitness for a particular purpose.

MORE INFORMATION

In the native format, as supplied with Word for Windows, the MEMO2.DOT template inserts designated names on the TO: and CC: lines of a memo separated by commas, as shown below:

   TO: Bob Hawley, Ed Paulson, Steve Vaughan

   CC: Don Ellis, Mark Gibson, Susan Dodd

Note: This modification affects only individual names you insert in the TO: or CC: lines. If you insert a group on these lines, the template lists the group names on the same line, separated by commas.

The following instructions modify the MEMO2.DOT AutoNew macro so it inserts each name on the TO: and CC: lines of a memo on a separate line:

  1. Open the MEMO2.DOT template file. From the Tools menu, choose Macro.

  2. In the Show box, select the Template Macros option.

  3. From the Macro Name list, select Autonew and choose the Edit button.

  4. From the Edit menu, choose Replace.

  5. In the Find What box, type the following (be sure to type a space after the comma):

    Insert ", "

  6. In the Replace With box, type the following and choose the Replace All button (be sure to type a space between the quotation marks):

    Insert " " + chr$(11)

    Note: Word should make two replacements.

  7. In the Find What box, type the following:

    Insert Display$(counter) + ", "

  8. In the Replace With box, type the following and choose the Replace All button (be sure to type a space between the quotation marks):

    Insert Display$(Counter) + " " + Chr$(11)

    Note: Word should make one replacement.

  9. Choose the Close button.

  10. From File menu, choose Close.

  11. When Word prompts you to save changes to the AutoNew macro, choose the OK button.

REFERENCES

"Microsoft Word for Windows User's Guide," version 2.0, pages 784-786


KBCategory: kbmacro
KBSubcategory: kbtemplate
Additional query words: shipped 2.0 2.0a 2.0a-CD 2.0b 2.0c
winword2 winword modify


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: July 30, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.