Re: Microsoft word 2007, and replacing tabs with a space.


Lisle, Ted (CHFS DMS)
 

Here’s where a relatively obscure JAWS feature like listing ASCII values really pulls its weight.  This kind of under-the-hood discussion reminds me of my years with DOS, and (believe me) that’s no criticism.  I learned a lot back then.

 

Ted

From: main@jfw.groups.io [mailto:main@jfw.groups.io] On Behalf Of Brian Vogel
Sent: Monday, July 11, 2016 12:07 AM
To: main@jfw.groups.io
Subject: Re: Microsoft word 2007, and replacing tabs with a space.

 

Dave,

           The example you give of what you wanted to do is where the power of wildcards really comes in.  Lets say you're interested in replacing any one of the digits 0 through 9 that's followed by a space with that same digit followed by a period and a space.

            Your find string would be "([0-9])( )"  without the quotes, of course, and there is a single space between the second open and close parenthese.  This snags any digit zero through nine followed by a space in the find and the digit found will be available in the replace by the special denotation \1  (backslash followed by one).  The space itself is available using backslash followed immediately by two, but that's more trouble than it's worth here, but isn't if the thing captured is more complex than a space.

            Your replace string would be "\1. " without the quotes, which gives you the digit you captured followed immediately by a period followed immediately by a space.

            This is an incredibly powerful facility.  I only wish that Microsoft had implemented it using regular expressions instead of their own syntax, as this is the concept behind the wildcards, but they're not nearly so flexible as true regular expressions are.  That, however, is beyond the scope here.
--
Brian


A great many people think they are thinking when they are merely rearranging their prejudices.

         ~ William James

Join main@jfw.groups.io to automatically receive all group messages.