Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.docmanagement
binar binar is offline
external usenet poster
 
Posts: 90
Default Find & Replace Wildcard Expression for Ordinal Numbers

Fellow Forum Members,
I need to erase a lot of paragraph numbers (shown below) using a Find &
Replace operation. The problem is that 9 has one digit and "10" has two
digits and "120" has three digits. Using the FIND & REPLACE expression
"^#.^#.^#.^#.^#" leaves behind "0" for "10" and "20" for "120". The flaw with
this expression is that it's looking for CARDINAL numbers. Can anyone help me
in developing a wild card expression that will find whatever ORDINAL number
no matter how many digits an allow me to erase it in one single Find &
Replace operation. Thanks in advance for any help.



3.2.1.3.9 Item 1
3.2.1.3.10 Item 2
3.2.1.3.11 Item 3
3.2.1.3.120 Item 3
  #2   Report Post  
Posted to microsoft.public.word.docmanagement
Graham Mayor Graham Mayor is offline
external usenet poster
 
Posts: 19,312
Default Find & Replace Wildcard Expression for Ordinal Numbers

Look for
[0-9]{1,}.[0-9]{1,}.[0-9]{1,}.[0-9]{1,}.[0-9]{1,}
or
[0-9.]{9,}
if there are no other large blocks of numbers
See http://www.gmayor.com/replace_using_wildcards.htm

--

Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org


binar wrote:
Fellow Forum Members,
I need to erase a lot of paragraph numbers (shown below) using a Find
& Replace operation. The problem is that 9 has one digit and "10" has
two digits and "120" has three digits. Using the FIND & REPLACE
expression "^#.^#.^#.^#.^#" leaves behind "0" for "10" and "20" for
"120". The flaw with this expression is that it's looking for
CARDINAL numbers. Can anyone help me in developing a wild card
expression that will find whatever ORDINAL number no matter how many
digits an allow me to erase it in one single Find & Replace
operation. Thanks in advance for any help.



3.2.1.3.9 Item 1
3.2.1.3.10 Item 2
3.2.1.3.11 Item 3
3.2.1.3.120 Item 3



Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
find and replace NUMBERS Andy Tables 1 May 12th 07 08:50 PM
find and replace numbers using wildcards Andy Microsoft Word Help 1 May 12th 07 07:42 PM
Wildcard expression? RedRado03 Microsoft Word Help 1 July 5th 06 05:46 PM
How do I replace a parenthetical expression? Visit the Sky Microsoft Word Help 4 June 15th 06 09:26 PM
Default to No Superscript for ordinal numbers (e.g. 12th, 2nd, etc Andrea Microsoft Word Help 2 February 10th 06 10:38 PM


All times are GMT +1. The time now is 05:16 PM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"