Word doesn't seem to comply to its own regex documentation. To some degree, this might be helped by using the Special drop down in the Search and Replace box. In my case, it inserts {;} instead of the documented {,} for Number of repetitions. (Once you know about the semi colon instead of the comma, you may of course insert this yourself... - On the other hand: This does seem to be different even between different versions of Word.) Talking of repetitions, Word exhibits significant trouble in handling these.
You might want to verify this searching your example and a small addition
1.0 ...
...
2.4.3 ...
...
6.18.21.8 ...
...
...1.0 ...
with ^13([0-9]@.)@[0-9]@
. It actually should match the first three number - dot - sequences at the start of the respective lines - but not the fourth, where the line starts with other characters. However, on my version of word, it just matches the very first one. This is in line with ^13([0-9]{1;}.){1;}[0-9]{1;}
matching the first one, only - and ^13([0-9]{1;}.){2;}[0-9]{1;}
not matching anything at all. (Which mirrors at the same time your observation about repetitions of the exact sequence instead of the pattern to be matched.)
You might want to check the transcription in RegEx 101 as a proof of concept.
The closest possible to your requirements is probably either:
^13[0-9.]{1;}
(with the tuned up ^13[0-9.]{1;}.[0-9]{1;}
again not working at all) - which unfortunately accepts patterns, you actually want to see excluded, or
- running
^13[0-9]{1;}.[0-9]{1;}
, ^13[0-9]{1;}.[0-9]{1;}.[0-9]{1;}
, ^13[0-9]{1;}.[0-9]{1;}.[0-9]{1;}.[0-9]{1;}
, etc., which lacks much of the regex beauty/flexibility - but is much more rigid.
Depending on your overall requirements, you might be better off using a different tool for that particular job.
BTW:
- Word uses ? instead of . to denote any character. This is, why the dot does not need to be escaped in the above expressions.
- Word should actually accept dot or backslash for
[\.]
- but requires [\\.]
instead (in my version).
- "Some number of iterations of the preceding two steps" is (along your sample code) read as meaning minimum once.
- The trailing blanks in the above regex are lost due to the handling of blanks in HTML.
- If you are using Words functionality for headings (meaning in particular the use of the respective heading styles): Did you at all try using the Outline view (perhaps with the text body not shown) to further your purpose ?