View Single Post
 
Old 10-04-2013, 05:08 AM
sleake sleake is offline Windows XP Office 2007
Advanced Beginner
 
Join Date: Jul 2011
Posts: 60
sleake is on a distinguished road
Default How to Turn Off Message "Search from the beginning of a document" in a Macro

I've put together a macro (attached) for our group of editors to use for cleaning up documents to:
  • Add two spaces after a period (a recent "edict" that we all hate!)
  • Remove spaces between words and before punctuation marks of various types
  • Search for two periods and replace with one
Because I don't know how to write "elegant" code, I created separate macros and strung them together in a single macro. It gets the job done with spaces, but each time one of the macros runs, there's a message about continuing the search from the begining of the document (I used Replace all).

How do I suppress those messages, yet ensure that Word continues searching from the beginning? It's a pain to keep clicking OK (and not very elegant besides).

Also, if you have any suggestions about re-writing the code to make it cleaner, I'd appreciate your help.
Attached Files
File Type: docx AddRemoveSpaces Macro.docx (17.5 KB, 10 views)
Reply With Quote