Search and Replace

J

Johann Swart

My apologies; this is probably not the correct newsgroup
for posting 'Search & Replace' queries, but I don't seem
to find a logical newsgroup for this.
I need to replace the current decimal point (full stop,
period) in documents with a decimal comma (our company and
national standard). There are literally thousands in
thousands of documents, so doing it manually is not really
an option.
All instances of figures have a digit in front of the
decimal (0 to 9), so searching for decimals is not really
a problem if I use the ^#.^#, but replacing only the point
between the two digits with a comma, is where my problem
lies. I have looked at some MVP documents, but it does not
appear as if this situation is adressed.

Office 97 Pro
Win2K Pro
 
K

Klaus Linke

Hi Jonathan,

You need a wildcard replacement:
Find what: ([0-9]).([0-9])
Replace with: \1,\2

It may get hairy, though, if numbers already use the "," as a grouping symbol (1,000.0).
In that case, you may need to find numbers with a macro (searching for [0-9,.]{2,} using wildcards, for example), and then parse the
number.
I have looked at some MVP documents, but it does not
appear as if this situation is adressed.

Try http://word.mvps.org/FAQs/General/UsingWildcards.htm

Regards,
Klaus
 
J

Johann Swart

Danke schön, Klaus, exactly what I was looking for.
Fortunately, my figures use a space for grouping, so no
problem there.

I did look at the website you suggested, and I did see
this technique, but did not fully understand its
application. Thanks a million!

Regards

Johann

-----Original Message-----
Hi Jonathan,

You need a wildcard replacement:
Find what: ([0-9]).([0-9])
Replace with: \1,\2

It may get hairy, though, if numbers already use the ","
as a grouping symbol (1,000.0).
In that case, you may need to find numbers with a macro
(searching for [0-9,.]{2,} using wildcards, for example),
and then parse the
number.


Try http://word.mvps.org/FAQs/General/UsingWildcards.htm

Regards,
Klaus


"Johann Swart" <[email protected]> schrieb im
Newsbeitrag news:[email protected]...
 
Top