atw: Re: Mistakes and editing
- From: "Howard Silcock" <howard.silcock@xxxxxxxxxxxx>
- To: <austechwriter@xxxxxxxxxxxxx>
- Date: Sun, 8 Oct 2006 14:03:35 +1000
Hi Mark,
Slightly quicker is to put in the Find box (again with the Use wildcards
checkbox selected):
space{2,}
(again use an actual space, here and below, in place of the word 'space')
and then you can just put
space
in the Replace box.
This also replaces any two or more consecutive spaces with a single space.
It's also sometimes useful to modify this recipe by putting the tab symbol
^t in the Replace box. This replaces two or more consecutive spaces by a
tab, which is sometimes useful when you have a document in which the text's
in columns created using consecutive spaces - for example, when you get
plain-text output from a command-line interface. (Here's an example that
comes to mind. I sometimes use the DOS command dir to get a listing of a
folder, then I want to put the output into Word. The output is in columns
separated by multiple spaces, which looks OK in a fixed-width font, but
doesn't work when I convert to a proportionally spaced font. If I replace
multiple spaces by tabs, it's easier to get the columns to line up.)
Sometimes you might want to replace only *three or more* spaces by a tab -
for instance, if the author still follows the ancient practice of using two
spaces after a full stop and you don't want a tab to appear at the end of
every sentence. In that case, just replace the Find box entry by
space{3,}
(You could also use this in the first example if you wanted to replace every
string of three or more consecutive spaces with a single space but still
leave a double space after every full stop - some places still recommend
this usage in their style guides, though I can't understand why. But of
course then you wouldn't catch any unwanted double spaces between words
either.)
Howard
Mark K wrote:
> While on the topic of mistakes and editing I found this which I think most
> will find incredibly useful - a quick way to find and replace multiple
> spaces between words in a Word document.
> In the Find Replace dialog box, select the Wildcard checkbox, then type
the
> following expression in the Find what box, repalcing the word "space" with
> an actual space:
> space[space]@([!space])
> Type the following expression in the Replace box, also replacing the word
> "space" with an actual space.
> space\1
> This will find and replace multiple spaces between words.
> I found this on http://vbaexpress.com <http://vbaexpress.com/> in the
Word Macro section. I think you
> have to be a member to see code examples though.
> Cheers Mark
**************************************************
To post a message to austechwriter, send the message to
austechwriter@xxxxxxxxxxxxxx
To subscribe to austechwriter, send a message to
austechwriter-request@xxxxxxxxxxxxx with "subscribe" in the Subject field.
To unsubscribe, send a message to austechwriter-request@xxxxxxxxxxxxx with
"unsubscribe" in the Subject field.
To search the austechwriter archives, go to
www.freelists.org/archives/austechwriter
To contact the list administrator, send a message to
austechwriter-admins@xxxxxxxxxxxxx
**************************************************
Other related posts: