4

I need to do a search and replace for the text below in Microsoft Word.

Skill No 24:

And replace it with:

Skill No: 24

What should the syntax be?

2 Answers 2

7

You could find:

Skill No ([0-9]{1,}):

And replace with:

Skill No: \1

Don't forget to check 'Use wildcards'

2
  • 1
    If your Word installation is done in a culture different from enUS, Word kindly changes the separator in regular expressions, so that above will become Skill No ([0-9]{1;}):. Notice the comma vs semicolon.
    – MyICQ
    Jan 31, 2022 at 12:40
  • @MyICQ Ah, thanks for pointing that out!
    – Jerry
    Feb 4, 2022 at 7:22
1

Find:

Skill No (\d+):

Replace:

Skill No: \1
1
  • in MS-WORD \d dosent mean a digit.
    – dovid
    Apr 26, 2015 at 10:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .