Follow these steps to add this Macro to a Microsoft Word or Excel document:

  1. Open Microsoft Word or Excel
  2. Go to View -> Macros -> View Macros
  3. Change Macros in to the current file
  4. Give your macro a name (any name is OK)
  5. Click Create
  6. Clear the editor
  7. Press Copy Macro to copy the macro to your clipboard.
  8. Paste the macro
  9. Close the macro editor window
  10. Save the document as a macro-enabled document